A simple text statistics analyzer for Python
Project description
TextStats
A lightweight Python package for text statistics and analysis.
installation
pip install textstatscomp
Quick Start
from textstats import TextStats
text = "Your text here. This is a sample sentence."
Create analyzer stats = TextStats(text)
Get statistics print(f"Words: {stats.word_count()}") print(f"Sentences: {stats.sentence_count()}") print(f"Lexical Diversity: {stats.lexical_diversity()}")
Print full report stats.print_report()
Features
- Word, character, sentence, and paragraph counts
- Vocabulary analysis and lexical diversity
- Word frequency distribution
- Reading time estimation
- No external dependencies
License
MIT License
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file textstatscomp-0.1.1.tar.gz.
File metadata
- Download URL: textstatscomp-0.1.1.tar.gz
- Upload date:
- Size: 4.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
680e0495d22aa58526aec7fe108c83f6d3993d980d9b21d4e4757da18987fd02
|
|
| MD5 |
a493fda8fe3d2d896a6364b2fea3c73e
|
|
| BLAKE2b-256 |
b7821bd9d4a89b13c76e2e872952ca0e5353917e5eb9dabc28f9cdfad2c99459
|
File details
Details for the file textstatscomp-0.1.1-py3-none-any.whl.
File metadata
- Download URL: textstatscomp-0.1.1-py3-none-any.whl
- Upload date:
- Size: 4.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
59ef59867b78305f6b544b28eae7c86fbb14c5cb9e6bc4d390ce540bb3ee249b
|
|
| MD5 |
b8013526334f3af011ca5a4394235a98
|
|
| BLAKE2b-256 |
2e83fc3f00fcfe266731325323a680e3d72282b12179902c4f90dd25c837a0e5
|