Description Usage Arguments Examples
Return the proportion of sparseness of a document-feature matrix, equal to the proportion of cells that have zero counts.
1 | sparsity(x)
|
x |
the document-feature matrix |
1 2 3 | dfmat <- dfm(data_corpus_inaugural)
sparsity(dfmat)
sparsity(dfm_trim(dfmat, min_termfreq = 5))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.