Correlation Calculators
0 calculators tagged with “Correlation”
All Calculators
No calculators found for this topic.
Pearson Correlation (r)
r = Σ[(xᵢ−x̄)(yᵢ−ȳ)] / √[Σ(xᵢ−x̄)² × Σ(yᵢ−ȳ)²]
Or: r = COV(X,Y) / (SD_X × SD_Y). Interpretation: |r| 0.9–1.0 = very strong; 0.7–0.9 = strong; 0.5–0.7 = moderate; 0.3–0.5 = weak; < 0.3 = negligible. Assumptions: both variables normally distributed; linear relationship; no significant outliers.
Significance Test
t = r √(n−2) / √(1−r²); df = n−2. Example: r = 0.65, n = 25 (df=23): t = 0.65 × √23 / √(1−0.4225) = 3.40; p < 0.01.
r² (Coefficient of Determination)
r² = proportion of variance in Y explained by X. r = 0.70 → r² = 0.49 → 49% of Y variance explained by X. The remaining 51% is due to other factors.
Spearman's Rho
Convert both variables to ranks; calculate Pearson r on the ranks = Spearman ρ. Use when: data ordinal; non-normal distribution; outliers present; relationship is monotonic but not linear.
Glossary
Frequently Asked Questions
Correlation measures the statistical association between two variables — how much they tend to change together. Pearson r: measures the strength and direction of a linear relationship. r = +1: perfect positive linear relationship (both increase together). r = −1: perfect negative linear relationship. r = 0: no linear relationship (may still be non-linear relationship). Interpretation: |r| > 0.7 = strong; 0.5–0.7 = moderate; 0.3–0.5 = weak. r measures only linear association — if the relationship is curved (e.g., U-shaped), r may be near 0 even though the relationship is strong.
H₀: ρ = 0 (no linear correlation in the population). Test statistic: t = r√(n−2)/√(1−r²); df = n−2. Example: r = 0.50, n = 30 (df=28): t = 0.50×√28/√(1−0.25) = 0.50×5.292/0.866 = 3.06; p ≈ 0.005 → significant at α = 0.05. Software: R: cor.test(x, y, method='pearson'); Python: scipy.stats.pearsonr(x, y). Note: with large n, even tiny r values are statistically significant (e.g., r = 0.10 is significant with n = 400) but not necessarily meaningful. Always report r and the CI alongside the p-value.
Pearson r: assumes linear relationship; assumes both variables approximately normally distributed; sensitive to outliers; calculates on raw values. Spearman's rho (ρ): non-parametric; converts values to ranks, then calculates Pearson r on ranks; does NOT assume normality or linearity — only that the relationship is monotonic (consistently increasing or decreasing); robust to outliers and extreme values. Use Spearman when: data are ordinal (rankings, Likert scales); distribution is non-normal (skewed, heavy-tailed); outliers cannot be removed; scatter plot shows monotonic but non-linear relationship. Both are interpreted the same way (−1 to +1) but Spearman is less powerful than Pearson when Pearson's assumptions are met.
'Correlation does not imply causation' — one of the most important principles in science. A correlation between X and Y can arise from: Direct causation: X causes Y or Y causes X. Common cause (confounding): a third variable Z causes both X and Y — creating a spurious correlation. Coincidence: random co-occurrence — especially common in small samples or when many variables are examined (multiple testing). Reverse causation: Y causes X, not the other way around. Examples: ice cream sales correlate with drowning rates (common cause: hot summer). Stork populations correlate with human birth rates in Europe (common cause: both correlated with rural area). To establish causation: randomized controlled experiment (RCT) or rigorous natural experiment; Bradford Hill criteria in epidemiology; temporal precedence (cause must precede effect); plausible mechanism.