Description Usage Arguments Plot Examples
The elements of the Co occurrence matrix indicate how many times two words co-occur in a (sliding) word window of a given size.
1 2 3 4 |
corpus |
A |
window |
Size of the sliding word window. |
normalize |
Whether to normalize the counts by the distance between word positions. |
The plot method returns an object of class echarts4r
.
1 2 3 4 5 6 7 8 9 10 11 12 13 | ## Not run:
init_textanalysis()
# create corpus
doc <- string_document("A simple document.")
doc2 <- string_document("Another simple document.")
crps <- corpus(doc, doc2)
# matrix & plot
matrix <- coom(crps)
plot(matrix)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.