A Python Package to perform Exploratory Data Analysis on Text Data.
Project description
Text_Explore
A Python Library to perform Exploratory Data Analysis on Text
Install Package
pip install text_explore
Using Package
-
Access from class
# Access from a single class from text_explore import TextExplore text = """US actor Jussie Smollett has been sentenced to 150 days in jail after a jury found he lied to police about being the victim of a hate crime. The former Empire star, 39, was found guilty in December of five charges of felony disorderly conduct after making false reports about the hoax attack. The sentence also includes 30 months of probation and $145,000 (£110,000) in restitution and fines. Following the sentence, Smollett said: "I did not do this!" The trial stemmed from an incident three years ago when Smollett said he was attacked by two assailants. The actor, who is black and gay, said the attackers shouted slurs at him and a Trump slogan, dumped a "chemical substance" on him and tied a noose around his neck while he was walking late at night in January 2019.""" doc = TextExplore(text) # Count Number of Words in Text print("Word Count:", doc.count_words()) # Count Number of Characters in Text print("Characters Count:", doc.count_chars()) # Count Number of Stopwords in Text print("Stopwords Count", doc.count_stopwords()) # Count Number of Syllables in Text print("Syllables Count:", doc.count_syllables()) # Count Number of Sentences in Text print("Sentences Count:", doc.count_sentences()) # Flesch reading ease score print("Flesch reading ease:", doc.flesch_reading_ease()) # Flesch kincaid grade score print("Flesch kincaid grade:", doc.flesch_kincaid_grade())
-
Access individual functions
# Access individual functions from text_explore.counts import ( count_words, count_chars, count_stopwords, count_syllables, count_sentences, ) from text_explore.readability import ( flesch_kincaid_grade, flesch_reading_ease ) # Count Number of Words in Text print("Word Count:", count_words(text)) # Count Number of Characters in Text print("Characters Count:", count_chars(text)) # Count Number of Stopwords in Text print("Stopwords Count", count_stopwords(text)) # Count Number of Syllables in Text print("Syllables Count:", count_syllables(text)) # Count Number of Sentences in Text print("Sentences Count:", count_sentences(text)) # Flesch reading ease score print("Flesch reading ease:", flesch_reading_ease(text)) # Flesch kincaid grade score print("Flesch kincaid grade:", flesch_kincaid_grade(text))
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
text_explore-0.0.2.tar.gz
(5.3 kB
view details)
Built Distribution
File details
Details for the file text_explore-0.0.2.tar.gz
.
File metadata
- Download URL: text_explore-0.0.2.tar.gz
- Upload date:
- Size: 5.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.12 CPython/3.8.10 Linux/5.13.0-28-generic
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 88b914d1f2d4e055b4453c389a14d6182fe2871e1f3a505e856529a1c73b8ce2 |
|
MD5 | c0199aa287f11525f70794b6daf6ae74 |
|
BLAKE2b-256 | f54420de0f8d9fd4834f566e6409aeb74d7deb52edb89df8b4e793821a11c641 |
File details
Details for the file text_explore-0.0.2-py3-none-any.whl
.
File metadata
- Download URL: text_explore-0.0.2-py3-none-any.whl
- Upload date:
- Size: 6.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.12 CPython/3.8.10 Linux/5.13.0-28-generic
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c0227f56a389b6a7cd16fcfea1d94afd91abd168a1e5ee27299a8769473350f0 |
|
MD5 | fad041ae26e24f478847fc781a63fda3 |
|
BLAKE2b-256 | 2840172e8aa0a414c0eeeeb8083357c6a4a569b4f5b28d2c2879406abc7a2310 |