Learn R Programming

koRpus (version 0.13-8)

MATTR: Lexical diversity: Moving-Average Type-Token Ratio (MATTR)

Description

This is just a convenient wrapper function for lex.div.

Usage

MATTR(txt, window = 100, char = FALSE, ...)

Arguments

txt

An object of class kRp.text containing the tagged text to be analyzed.

window

An integer value for MATTR, defining how many tokens the moving window should include.

char

Logical, defining whether data for plotting characteristic curves should be calculated.

...

Further valid options for the main function, see lex.div for details.

Value

An object of class kRp.TTR.

Details

This function calculates the moving-average type-token ratio (MATTR). In contrast to lex.div, which by default calculates all possible measures and their progressing characteristics, this function will only calculate the MATTR value.

References

Covington, M.A. & McFall, J.D. (2010). Cutting the Gordian Knot: The Moving-Average Type-Token Ratio (MATTR). Journal of Quantitative Linguistics, 17(2), 94--100.

See Also

kRp.POS.tags, kRp.text, kRp.TTR

Examples

Run this code
# NOT RUN {
MATTR(tagged.text)
# }

Run the code above in your browser using DataLab