Correlation coefficient calculator
Paste two lists of numbers to measure how strongly they move together. You get Pearson’s r, r², the line of best fit and a p-value, with the data drawn as a scatter plot.
- Means: x̄ = 4.5, ȳ = 9.025
- Sums of squares and products: Sxx = 42, Syy = 167.795, Sxy = 83.9
- r = Sxy ÷ √(Sxx × Syy) = 83.9 ÷ √(42 × 167.795) = 0.999419
How to use it
- 1Paste the x values in the first box and the y values in the second, in matching order.
- 2Read r and what it means from the results.
- 3Check the scatter plot. A correlation only describes a straight-line trend, so it can mislead if the pattern is curved.
How to read r
The correlation coefficient r runs from −1 to 1. Its sign gives the direction: positive means y tends to rise with x. Its size gives the strength: 0 means no straight-line relationship, and ±1 means the points lie exactly on a line.
| |r| | A common reading |
|---|---|
| 0.9 to 1 | Very strong |
| 0.7 to 0.9 | Strong |
| 0.4 to 0.7 | Moderate |
| 0.2 to 0.4 | Weak |
| Below 0.2 | Very weak or none |
These labels are only conventions, and what counts as strong varies by field.
The formula
Pearson’s r is Sxy ÷ √(Sxx × Syy), where Sxx = Σ(x − x̄)², Syy = Σ(y − ȳ)² and Sxy = Σ(x − x̄)(y − ȳ). Squaring it gives r², the share of the variation in y that the line accounts for: r = 0.8 means r² = 0.64, or 64%.
What correlation can’t tell you
- Causation. Ice cream sales and drownings both rise in summer. Neither causes the other; hot weather drives both.
- Curved relationships. Points on a perfect U-shape can have r = 0, so always look at the plot.
- Outliers. A single extreme point can create or hide a strong correlation.
Frequently asked questions
What is a good correlation coefficient?
What is the difference between r and r²?
What does the p-value mean here?
Does this calculate Spearman’s correlation?
Related tools and guides
Paste data, add a line of best fit, download as PNG or SVG.
Linear, polynomial, exponential or any custom model, with error bars.
Sample or population, with variance, every step and a histogram.
P-values from data or statistics, shaded on the distribution.
Value to z-score, z-score to percentile, and back.
It opens instantly, with no account and nothing to install.