as.matrix.dsm | R Documentation |
Extract the co-occurrence or score matrix from a DSM object.
## S3 method for class 'dsm' as.matrix(x, what = c("auto", "M", "S"), ...)
x |
an object of class |
what |
whether to extract the raw co-occurrence matrix ( |
... |
any additional arguments are ignored |
This function ensures that the row and column names of the matrix are consistent with the row/column information tables of the DSM.
For faster access to the matrix, simply use x$M
or x$S
directly.
Either the raw co-occurrence matrix or the score matrix of the DSM x
.
Note that unlike other as.matrix
methods, a sparse matrix in canonical DSM format may be returned.
Stephanie Evert (https://purl.org/stephanie.evert)
dsm
, dim.dsm
, dimnames.dsm
, dsm.is.canonical
as.matrix(DSM_TermTerm) as.matrix(DSM_TermContext)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.