View source: R/transform_dfm.R
transform_dfm | R Documentation |
Applies bounds, weights, and/or coarsening schemes to a dfm or document frequency matrix to reduce the dimension of the data, reduce noise, or apply other design rules (e.g. - to exclude words that occur in too few or too many documents).
transform_dfm(x, bounds, tfidf = FALSE, verbose = TRUE)
x |
a matrix text representation with rows corresponding to each document in a corpus and columns
that represent summary measures of the text (e.g., word counts, topic proportions, etc.). Acceptable forms include
a valid quanteda |
bounds |
a vector of lower and upper bounds to enforce. Defaults to excluding any terms that appear in only one document and any terms that appear in every document |
tfidf |
optional scheme to use for weighting the DTM. Defaults to |
verbose |
indicator for verbosity |
A bounded DFM
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.