View source: R/calc_correlation.r
calc_correlation | R Documentation |
Computation of correlation coefficients.
calc_correlation(x, y, type = c("pearson", "kendall", "spearman"))
x |
A numeric vector |
y |
A numeric vector |
type |
A character single value, that is the type of the correlation to be computed |
Currently, it is possible to compute the following metrics:
- Kendall's Tau correlation coefficient
- Pearson linear correlation coefficient
- Spearmann correlation coefficient
A numeric single value with the computed value.
x <- rnorm(100,1)
calc_correlation(x,x)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.