How to Test a Correlation for Significance

Tests whether a correlation coefficient is too large to be put down to chance. The statistic t = r√(n−2) ÷ √(1−r²) follows a t distribution with n−2 degrees of freedom. In a small sample, an apparent correlation comes easily.

This asks whether a correlation coefficient is large enough to take seriously, or merely what chance would throw up. Assuming no correlation in the population, it measures how unlikely the observed rr would be.

t=rn21r2t = \dfrac{r\sqrt{n-2}}{\sqrt{1-r^2}}

This tt follows a t distribution with n2n-2 degrees of freedom. If t|t| beats the critical value, the assumption of no correlation becomes hard to hold.

Example

Eight pairs give a correlation of 0.965. Then t=0.965×6÷10.932=9.05t = 0.965 \times \sqrt{6} \div \sqrt{1 - 0.932} = 9.05. With 6 degrees of freedom the 5% critical value is 2.45, which this far exceeds. The p-value is 0.0001, so no correlation is a poor explanation.

Small samples produce correlations easily

With only three points, even a correlation of 0.99 fails to reach significance, because few points line up neatly by chance quite often. With a thousand points, an rr of 0.07 is significant. Being significant and being strong are different questions.

Significant is not causal

A significant correlation does not make one variable the cause of the other. Some third factor may move both, or it may simply be coincidence.

Notes

If every point lies exactly on a line, rr is exactly ±1\pm 1, the denominator is 0 and no tt exists.