formatMatrix | R Documentation |
Format a matrix and add index column.
formatMatrix(
x,
rnames = rownames(x),
pre.index = c(T, F),
cnames = seq_len(ncol(x)),
indexcol = F,
digits = 2,
diag = F,
mode = 1
)
x |
A matrix object. |
rnames |
Row names. |
pre.index |
Whether to make index prefix for rows and column names. |
cnames |
Column names. |
indexcol |
Whether to make an index column. |
diag |
Whether to show diagonal. |
mode |
Whether to show upper (mode=1), lower (mode=2) or both triangles (mode=0) of the matrix. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.