# NOT RUN {
mat <- rbind(dfm(c("b A A", "C C a b B"), tolower = FALSE, verbose = FALSE),
dfm("A C C C C C", tolower = FALSE, verbose = FALSE))
colnames(mat) <- char_tolower(featnames(mat))
mat
compress(mat, margin = "documents")
compress(mat, margin = "features")
compress(mat)
# no effect if no compression needed
compress(dfm(data_corpus_inaugural, verbose = FALSE))
# }
Run the code above in your browser using DataLab