Calculates correlation between two (symmetrical) matrices using 'stats::cor'
1 2 3 4 5 6 | calc_matrix_correlation(
m1,
m2,
zeros_remove = FALSE,
method = c("pearson", "kendall", "spearman")
)
|
m1, m2 |
The two matrices. Function only keeps row and colnames that exist in m1 and m2. |
zeros_remove |
Should all zeros be removed? (set to NA before running 'cor'). |
method |
a character string indicating which correlation
coefficient (or covariance) is to be computed. One of
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.