Lexicalrichness

Latest version: v0.5.1

Safety actively analyzes 621469 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 3

0.5.1

What's Changed
* Pass through `within_sample` parameter in `vocd` (fixes 80, xhulianoThe1)
* Fix CTTR equation (fixes 77)
* Minor doc fixes
* Fixed path to `vocd` image

`LexicalRichness`

To install: `pip install lexicalrichness`

**Example usage**
python
from lexicalrichness import LexicalRichness

text example
text = """Measure of textual lexical diversity, computed as the mean length of sequential words in
a text that maintains a minimum threshold TTR score.

Iterates over words until TTR scores falls below a threshold, then increase factor
counter by 1 and start over. McCarthy and Jarvis (2010, pg. 385) recommends a factor
threshold in the range of [0.660, 0.750].
(McCarthy 2005, McCarthy and Jarvis 2010)"""

lex = LexicalRichness(text)

lex.vocd_fig(
ntokens=50, Maximum number for the token/word size in the random samplings
within_sample=100, Number of samples
seed=42, Seed for reproducibility
)

![image](https://user-images.githubusercontent.com/10510571/211709085-4b3a1b8a-c9e2-4c1f-b53d-8c60992aebc0.png)

**Full Changelog**: https://github.com/LSYS/LexicalRichness/compare/v0.4.1...v0.5.1

0.5.0

What's Changed
* Add new measures 65
- Yule's K
- Yule's I
- Herdan's Vm
- Simpson's D
* Add new measures to example notebook (example.ipynb) 70
* Add new measures to docs 71
* Add the example.ipynb to the docs 72
* Tidy up imports using isort 69

`LexicalRichness`

To install: `pip install lexicalrichness`

**Example usage**
python
from lexicalrichness import LexicalRichness

text example
text = """Measure of textual lexical diversity, computed as the mean length of sequential words in
a text that maintains a minimum threshold TTR score.

Iterates over words until TTR scores falls below a threshold, then increase factor
counter by 1 and start over. McCarthy and Jarvis (2010, pg. 385) recommends a factor
threshold in the range of [0.660, 0.750].
(McCarthy 2005, McCarthy and Jarvis 2010)"""

lex = LexicalRichness(text)

lex.vocd_fig(
ntokens=50, Maximum number for the token/word size in the random samplings
within_sample=100, Number of samples
seed=42, Seed for reproducibility
)

![image](https://user-images.githubusercontent.com/10510571/211709085-4b3a1b8a-c9e2-4c1f-b53d-8c60992aebc0.png)


**Full Changelog**: https://github.com/LSYS/LexicalRichness/compare/v0.4.1...v0.5.0

0.4.1

What's Changed
* Update README.rst by ekbrown in https://github.com/LSYS/LexicalRichness/pull/62
* LSYS Add useful links (61)
* LSYS Add links to docs in Section 7 of `README.rst` to reference details in docs (64)
* LSYS Remove LGTM (66)
* LSYS Fix Sphinx autodoc on RTD (67)

New Contributors
* ekbrown made their first contribution in https://github.com/LSYS/LexicalRichness/pull/62



`LexicalRichness`

To install: `pip install lexicalrichness`

**Example usage**
python
from lexicalrichness import LexicalRichness

text example
text = """Measure of textual lexical diversity, computed as the mean length of sequential words in
a text that maintains a minimum threshold TTR score.

Iterates over words until TTR scores falls below a threshold, then increase factor
counter by 1 and start over. McCarthy and Jarvis (2010, pg. 385) recommends a factor
threshold in the range of [0.660, 0.750].
(McCarthy 2005, McCarthy and Jarvis 2010)"""

lex = LexicalRichness(text)

lex.vocd_fig(
ntokens=50, Maximum number for the token/word size in the random samplings
within_sample=100, Number of samples
seed=42, Seed for reproducibility
)

![image](https://user-images.githubusercontent.com/10510571/211709085-4b3a1b8a-c9e2-4c1f-b53d-8c60992aebc0.png)

**GitHub**: https://github.com/LSYS/LexicalRichness
**Example** notebook: https://nbviewer.org/github/LSYS/LexicalRichness/blob/master/docs/example.ipynb
**Docs**: http://lexicalrichness.readthedocs.io/

**Full Changelog**: https://github.com/LSYS/LexicalRichness/compare/v0.3.0...v0.4.0

0.4.0

What's Changed
* Add utility to plot empirical voc-D curve (https://github.com/LSYS/LexicalRichness/issues/60)
* `matplotlib` is now a requirement (from `setup.py`)
* Update docs

To install: `pip install lexicalrichness`

**Example usage**
python
from lexicalrichness import LexicalRichness

text example
text = """Measure of textual lexical diversity, computed as the mean length of sequential words in
a text that maintains a minimum threshold TTR score.

Iterates over words until TTR scores falls below a threshold, then increase factor
counter by 1 and start over. McCarthy and Jarvis (2010, pg. 385) recommends a factor
threshold in the range of [0.660, 0.750].
(McCarthy 2005, McCarthy and Jarvis 2010)"""

lex = LexicalRichness(text)

lex.vocd_fig(
ntokens=50, Maximum number for the token/word size in the random samplings
within_sample=100, Number of samples
seed=42, Seed for reproducibility
)

![image](https://user-images.githubusercontent.com/10510571/211709085-4b3a1b8a-c9e2-4c1f-b53d-8c60992aebc0.png)

GitHub: https://github.com/LSYS/LexicalRichness
Example notebook: https://nbviewer.org/github/LSYS/LexicalRichness/blob/master/docs/example.ipynb
Docs: https://www.lucasshen.com/software/lexicalrichness/doc

**Full Changelog**: https://github.com/LSYS/LexicalRichness/compare/v0.3.0...v0.4.0

0.3.1

What's Changed
* Add workflow to test package from notebook by LSYS in https://github.com/LSYS/LexicalRichness/pull/54
* Add details of measures into docs by LSYS in https://github.com/LSYS/LexicalRichness/pull/55
* Fix path to images in docs by LSYS in https://github.com/LSYS/LexicalRichness/pull/56


**Full Changelog**: https://github.com/LSYS/LexicalRichness/compare/v0.3.0...v0.3.1

0.3.0

What's Changed
* Disallow string input if `tokenizer` =None (closes 12) by LSYS in https://github.com/LSYS/LexicalRichness/pull/38
* fix tokenizing of lists by LSYS in https://github.com/LSYS/LexicalRichness/pull/39
* add .gitignore and make by LSYS in https://github.com/LSYS/LexicalRichness/pull/41
* Linkify references and add papers in readme 43 solved by Sreetama2001 in https://github.com/LSYS/LexicalRichness/pull/46
* Added an example use case of the LexicalRichness tool by g-hurst in https://github.com/LSYS/LexicalRichness/pull/48
* Add voc-D measure (42) by LSYS in https://github.com/LSYS/LexicalRichness/pull/49
* Update docs by LSYS in https://github.com/LSYS/LexicalRichness/pull/51

New Contributors
* Sreetama2001 made their first contribution in https://github.com/LSYS/LexicalRichness/pull/46
* g-hurst made their first contribution in https://github.com/LSYS/LexicalRichness/pull/48

**Full Changelog**: https://github.com/LSYS/LexicalRichness/compare/v0.2.0...v0.3.0

Page 1 of 3

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.