ponderloop.com

Correlation Coefficient Calculator

One pair per line, x then y, separated by a comma, space or tab (a pasted spreadsheet range works). Up to 1,000 pairs. A first line of column names is skipped. Or put the x values here and the y values in the second box.

Up to 1,000 pairs.

Pearson correlation coefficient

r ≈ 0.96356

A very strong positive linear correlation (a rule of thumb): r² ≈ 0.92844 means about 92.844% of the variation in y goes with x along a straight line, from 10 pairs. p ≈ 7.3835 × 10⁻⁶, below 0.05, so r is statistically significant at the 5% level. The 95% confidence interval for r is ≈ 0.84901 to 0.99160. Spearman rank correlation: ρ ≈ 0.96341.

Pearson correlation

Pearson correlation coefficient (r)
≈ 0.96356
Coefficient of determination (r²)
≈ 0.92844
r² as a percentage
≈ 92.844%
Strength (rule of thumb)
Very strong, positive
t statistic
≈ 10.188
Degrees of freedom (n − 2)
8
p-value (two-tailed)
≈ 7.3835 × 10⁻⁶
95% confidence interval for r
≈ 0.84901 to 0.99160

Spearman rank correlation

Spearman rank correlation (ρ)
≈ 0.96341
Strength (rule of thumb)
Very strong, positive
t statistic
≈ 10.167
p-value (two-tailed)
≈ 7.4992 × 10⁻⁶
Tied values
x: 2 values in 1 tie group; y: 2 values in 1 tie group

The p-value uses the t distribution with n − 2 degrees of freedom, the usual approximation for ρ (SciPy’s spearmanr does the same); it is less reliable with fewer than about 10 pairs or many ties.

Working sums

Number of pairs (n)
10
Mean of x (x̄)
4.52
Mean of y (ȳ)
24.1
Sxx = Σ(x − x̄)²
25.096
Sxy = Σ(x − x̄)(y − ȳ)
95.68
Syy = Σ(y − ȳ)²
392.9
Σx
45.2
Σy
241
Σx²
229.4
Σy²
6,201
Σxy
1,185

Scatter plot

102030402468xy
10 pairs: x runs from 2.1 to 7.2 and y from 14 to 35. The line rises from left to right. Pearson r ≈ 0.9636.Each dot is one pair. The line is the least-squares line, drawn to show the direction of the trend; the closer the dots hug it, the closer |r| is to 1. The rank table below the plot lists the same pairs.

How strong is the correlation?

Rule-of-thumb bands for the size of |r| (the sign only gives the direction), and where your coefficients fall
|r| (or |ρ|)Labelr² (or ρ²)Your data
0.00 to below 0.20Very weak0 to below 0.04
0.20 to below 0.40Weak0.04 to below 0.16
0.40 to below 0.60Moderate0.16 to below 0.36
0.60 to below 0.80Strong0.36 to below 0.64
0.80 to 1.00Very strong0.64 to 1Pearson r and Spearman ρ

These labels are a rough convention, not a law: what counts as strong depends on the field, and a small n can make even a large r a fluke. The p-value and the confidence interval above say how much to trust it.

Rank table for Spearman’s ρ

Equal values share the average of the ranks they occupy, so a tie for ranks 2 and 3 gives both 2.5. Spearman’s ρ is Pearson’s r computed on these ranks.

Each pair with the rank of its x and of its y (1 is the smallest)
#xyRank of xRank of y
12.11411
22.81823
33.4173.52
43.4223.54
542455.5
64.72465.5
75.22777
85.93189
96.52998
107.2351010