print_square_matrix | R Documentation |
Helper function to produce output for square matrices, e.g. distance matrices etc. Adds a (trimmed) name and index column. Displays upper triangle only by default. The function is used inside the print method of several classes.
print_square_matrix(
x,
names = NA,
trim = NA,
index = TRUE,
width = NA,
upper = TRUE
)
x |
A square |
names |
names A vector of row names. |
trim |
Trimmed length of names (numeric). |
index |
Whether to add an index columns (default |
width |
Column width of output (numeric). |
upper |
Whether to only show the upper triangle (default |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.