Statistics

Correlation Coefficient Calculator

Calculate Pearson correlation coefficient (r), Spearman rank correlation (ρ), or Kendall’s tau (τ) from raw paired data or from summary stats. Get p-value (one- or two-tailed), confidence interval (Pearson via Fisher z), r², covariance, and the simple linear regression line.

Pearson r Spearman ρ Kendall τ p-value & CI
Note: Correlation describes association, not causation. P-values and confidence intervals rely on assumptions and can be sensitive to outliers.

Calculate Correlation

Choose a method and input format. You can paste data, enter pairs in a table, or compute Pearson r from summary totals.

Pearson r measures linear association.
Row X Y Remove
Spearman’s ρ is Pearson correlation computed on ranks. It is commonly used for ordinal data or for monotonic relationships. This tool uses average ranks for ties. The p-value uses a t-approximation (best for moderate/large n).
Good when outliers or non-linearity affect Pearson.
Handles ties via average rank.
Kendall’s τ measures concordance of pairs (how often rankings agree). It is useful for ordinal data and is often more conservative than Spearman. This tool computes τ-b (tie-adjusted). The p-value uses a normal approximation (best for larger n).
τ-b adjusts for ties in X and/or Y.
O(n²) pairs; very large n may be slow.
Use this mode when you don’t have raw data but you do have totals: n, Σx, Σy, Σx², Σy², Σxy. The calculator computes Pearson r, regression slope/intercept, and the correlation test p-value.