Pearson correlation
Pearson correlation: use x observations, y observations. Review the formula, worked example and calculation steps.
Inputs
Use the units shown—
Enter your values and select Calculate.
Formula & explanation
r = Σ[(x−x̄)(y−ȳ)] / √[Σ(x−x̄)² Σ(y−ȳ)²]
Variables & units
- X observations
- comma separated
- Y observations
- comma separated
Worked example
X=1,2,3 and Y=2,4,6 have correlation 1.
Assumptions
A linear relationship summary, not proof of causation. Constant variables are rejected.
Formula version 1.0.0. JavaScript floating-point arithmetic applies. Results display up to 6 decimal places; stored values retain available precision. Use the units shown.
Practice with an example
Use the default input values to find the answer. The reset icon restores those values.
Calculated on your device. Your latest 100 calculations stay in this browser.