[Durgical](https://durgical.com/en/) › [DurgiPedia](https://durgical.com/en/durgipedia/) › [Epidemiology](https://durgical.com/en/epidemiology/) › [Biostatistics](https://durgical.com/en/epidemiology/areas/stats/) › Correlation

# Correlation

- Measure

It measures how closely two numerical variables rise or fall together, from −1 to +1. It does not say that one causes the other.

Updated Nov 5, 2026

## Key points

- r runs from −1 (perfect negative linear relation) to +1 (perfect positive); 0 means no linear relation.
- r² (coefficient of determination) = the share of the variation in one variable explained linearly by the other.
- Spearman (ρ) uses ranks: it suits ordinal or skewed data and monotonic non-linear relations.
- Correlation is not causation: confounding, reverse causation or chance may explain it.
- r = 0 does not rule out a strong curved relation (for example U-shaped).
- Always look at the scatter plot: a single outlier can create or erase a correlation.

## What it is

A correlation coefficient sums up the strength and direction of the relation between two numerical variables. Pearson’s r measures the linear relation and assumes roughly normal data; Spearman’s ρ uses ranks and measures any monotonic relation, so it suits ordinal or skewed data. A strong correlation may come from confounding, reverse causation or chance: it is not proof of causation.

## Formula and reading

- r = Σ[(x − mean x)(y − mean y)] / √[Σ(x − mean x)² × Σ(y − mean y)²].
- Rough reading of the absolute value: 0.7 strong (cut-offs vary by field).
- r² = r × r; with r = 0.5, r² = 0.25: 25% of the variation is explained.

## Worked example

- Data: 5 adults; hours of exercise per week (x): 1, 2, 3, 4, 5; systolic pressure (y): 138, 137, 135, 128, 127 mmHg.
- Means: x = 3 hours; y = 665 / 5 = 133 mmHg.
- Deviations of x: −2, −1, 0, 1, 2. Deviations of y: 5, 4, 2, −5, −6.
- Sum of products = −10 − 4 + 0 − 5 − 12 = −31. Σ squared deviations of x = 10; of y = 25 + 16 + 4 + 25 + 36 = 106.
- r = −31 / √(10 × 106) = −31 / 32.6 = −0.95. r² = 0.91 (rounded).
- Spearman: the order of y is exactly the reverse of the order of x, so ρ = −1.
- Reading: a strong negative relation; it does not prove that exercise lowers pressure (5 people, no control of confounding).

## Markers

- r
- r²
- ρ

## Common pitfalls

- Inferring causation from a correlation.
- Using Pearson with curved relations, very skewed data or outliers without checking the plot.
- Confusing a significant correlation with a strong one: with many people, an r of 0.1 can give p

## Memory aid

‘They dance together, but nobody says who leads’: correlation shows two variables move together, not which one moves the other.

## Test yourself

Think of the answer, then tap the question to see it.

## What does r = −0.8 mean?

A strong negative linear relation: as one variable rises, the other tends to fall.

## If r = 0.6, what share of the variation is explained?

r² = 0.36: 36% of the variation in one variable is explained linearly by the other.

## When is Spearman’s correlation preferred to Pearson’s?

With ordinal data, skewed distributions or outliers, or when the relation is monotonic but not linear.

## A study finds a strong correlation between ice-cream sales and drownings. What explains it?

A confounder, hot weather, raises both. The correlation does not mean one causes the other.

[Add to my cards (4)](https://durgical.app/estudiar/?add=/en/epidemiology/correlation/)

## Connections

## Related 4

- [Linear regression](https://durgical.com/en/epidemiology/linear-regression/)
- [Non-parametric tests](https://durgical.com/en/epidemiology/non-parametric-tests/)
- [Chance, bias, confounding or cause](https://durgical.com/en/epidemiology/chance-bias-confounding-or-cause/)
- [Confounding](https://durgical.com/en/epidemiology/confounding/)

[← All of epidemiology](https://durgical.com/en/epidemiology/)

Educational content on epidemiological and statistical methods; the examples use made-up numbers to teach the calculation. Not a clinical or legal guide: current Colombian rules are in the official sources.

Sources: [Scatter Plot](https://www.itl.nist.gov/div898/handbook/eda/section3/scatterp.htm) (NIST/SEMATECH e-Handbook of Statistical Methods, National Institute of Standards and Technology, 2012); [Linear Least Squares Regression](https://www.itl.nist.gov/div898/handbook/pmd/section1/pmd141.htm) (NIST/SEMATECH e-Handbook of Statistical Methods, National Institute of Standards and Technology, 2012).

## **Spotted a mistake?** We are always improving for the community. Tell us what is wrong and our team will review it. Report a mistake

Representative model, for educational purposes only.

---
Source: https://durgical.com/en/epidemiology/correlation/
License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Cite as: DurgiPedia (durgical.com), https://durgical.com/en/epidemiology/correlation/
