Learn / Biostatistics / Correlation and linear regression
Correlation: strength of a straight-line relationship
12 minute read · 6-question quiz
What you will learn
Interpret a scatter plot and the Pearson correlation coefficient
Choose between Pearson and Spearman correlation
Explain why correlation is not causation and name the usual traps
Before computing anything with two continuous variables, draw the scatter plot. Each point is a person; the horizontal position is one variable and the vertical is the other. The cloud's shape tells you whether the relationship is rising, falling, curved, or absent, and shows outliers.
The Pearson correlation coefficient r summarises the strength and direction of a straight-line relationship on a scale from −1 to +1.
r = +1: perfect rising line;r = -1: perfect falling line;r = 0: no linear relationship.- Rough guide (varies by field): |r| below 0.3 weak, 0.3 to 0.7 moderate, above 0.7 strong.
What r does and does not tell you
- r² is the share of variation shared: 0.977² = 0.955, so about 96% of the variation in SBP in this sample is associated with age (in a straight-line sense).
- r measures linear association only. A perfect U-shaped relationship can have r ≈ 0.
- r is sensitive to outliers and to restricted ranges. A single extreme point can create or destroy a correlation.
- r is unit-free and symmetric: the correlation of age with SBP equals that of SBP with age.
- r says nothing about the slope: two data sets can have identical r but very different steepness. Regression (next lesson) gives the slope.
Spearman rank correlation
When data are skewed, ordinal or contain outliers, convert each variable to ranks and compute the correlation of the ranks: Spearman's ρ (rho). It detects any consistently rising or falling (monotone) relationship, curved or straight. For the example above, ρ = 0.979. Use Spearman for pain scales, CD4 against viral load (log it first or use Spearman), and any strongly non-normal data.
Correlation is not causation
Three common reasons for correlation without causation:
- Confounding: ice-cream sales and drownings both rise in hot weather. A third variable drives both.
- Reverse causation: depression and poor sleep are correlated, but which causes which?
- Chance and data dredging: compute enough correlations and some will be 'significant'. Spurious correlations abound (cheese consumption and deaths by bed-sheet tangling).
A further trap is the ecological fallacy: a correlation across districts (countries with more cell-phone use have lower child mortality) need not hold for individuals.
Summary
Always plot first; r only measures straight-line association.
r ranges from −1 to +1; r² is the proportion of variation shared.
Use Spearman's ρ for skewed, ordinal or outlier-prone data.
Correlation is not causation: confounding, reverse causation, chance and ecological fallacies.
Agreement between measurement methods needs Bland-Altman analysis, not r.
Check your understanding
Draft study guide. Spotted an error or something unclear? Tell us at hello@scintria.com. This is educational material, not clinical or regulatory advice.