Correlation Analysis (Pearson, Spearman, Kendall)
Computes Pearson r, Spearman ρ and Kendall τ including p-values and confidence intervals.
Description
Complete correlation analysis for two variables: parametric Pearson r (linear relationship), rank-based Spearman ρ (monotone relationship) and Kendall τ (pair-based concordance measure). For each method the correlation coefficient, t- or z-statistic, two-sided p-value, r² and Fisher- or normal-approximated confidence interval are returned.
Formulas
Assumptions
- For exact Pearson p-values: bivariate normality
- Spearman/Kendall: only a monotone relationship is required
- Observations are independent
Limitations
- Correlation does not imply causation
- Pearson is sensitive to outliers and non-linear relationships
- For perfect correlation (|r| = 1) the classical t-formula is singular — the implementation must handle this special case robustly
References
- Hollander, M., Wolfe, D. A., Chicken, E. (2013), Nonparametric Statistical Methods, 3rd Ed., Wiley
- NIST/SEMATECH e-Handbook of Statistical Methods, Section 1.3.5.13