Text processing and visualization with Python. First steps with Dash.
Created as training project to practice Dash and process text without external natural language processing tools.
Part of this script is reused from text-processing-with-regex
Text source: Lectures on The Language: An Introduction to the Study of Speech by Edward Sapir, 1921, www.gutenberg.org/Sapir | Lectures on the Science of Language by Max Müller, 1862, www.gutenberg.org/Muller
Actions
csv_generator.py: extracts ten most frequent words and ten longest sentences for each input text file, generates .csv files (words.csv, sentences.csv)
dash_visualization.py: gets .csv files and generates visualization with Dash
Interactive charts generated with script actions:
Scatterplot matrix of words and their frequency|length pairs
Stacked bar chart of word and their frequency|length pairs
Bubble chart of sentences with respect to their length|ranking
- Python 3.7
- Dash 1.4.0
To run this project, install dash with pip:
pip install dash==1.4.0
Input data: Lectures on The Language: An Introduction to the Study of Speech by Edward Sapir, 1921 (Sapir1921_chapter1.txt), Lectures on the Science of Language by Max Müller, 1862 (Muller1861_lecture1.txt), stopwords list (stopwordlist.txt)
Project is in progress. TODO:
- .csv files manipulation with pandas for Dash visualization
- restructuring sentences.csv
- bubble chart scaling correction
Created by @mal - feel free to contact me!