modMATRIX | R Documentation |
Create a matrix
modMATRIX(
x,
use = TRUE,
block = FALSE,
correlation = FALSE,
digits = -1,
context = "matlist",
...
)
x |
data for building the matrix. Data in |
use |
logical; if FALSE, all matrix elements are set to 0 |
block |
logical; if TRUE, try to make a block matrix; diagonal otherwise |
correlation |
logical; if TRUE, off diagonal elements are assumed to be correlations and converted to covariances; if correlation is TRUE, then block is set to TRUE |
digits |
if value of this argument is greater than zero, the matrix is passed to signif (along with digits) prior to returning |
context |
the working context |
... |
passed along |
modMATRIX("1 2.2 333")
modMATRIX("1 1.1 2.2", block=TRUE)
modMATRIX("23 234 234 5234", use=FALSE)
ans <- modMATRIX("1.1 0.657 2.2", correlation=TRUE, block=TRUE)
ans
cov2cor(ans)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.