IB Math AI HL Bivariate Statistics — Complete Cheatsheet
Scatter diagrams, Pearson's r, the coefficient of determination R², the least-squares regression line and Spearman's rank correlation for IB Mathematics Applications & Interpretation HL — fit the line on the GDC, predict with confidence, and separate correlation from causation. Built by an IBO-certified Singapore tutor, with a print-ready PDF to download.
Bivariate statistics is the modelling heart of the Statistics & Probability strand in IB Mathematics Applications & Interpretation HL. Instead of one list of numbers you are handed two variables measured on the same individuals — hours and marks, temperature and sales, dose and response — and asked whether they move together, how strongly, and what one lets you predict about the other. A calculator is always allowed, so the mechanical work — correlation coefficients, the line of best fit — takes a few keystrokes on the GDC. The marks live in choosing the right tool (Pearson versus Spearman, $y$ on $x$ versus $x$ on $y$), reading the value correctly, and interpreting it in context — above all, never mistaking correlation for causation.
This cheatsheet condenses SL 4.4 · 4.10 onto one page — scatter diagrams, Pearson's product–moment correlation coefficient $r$, the coefficient of determination $R^2$, the least-squares regression line and how to predict with it, outliers, and Spearman's rank correlation — and flags the traps that quietly cost marks (extrapolation, swapping the variables, confusing $r$ with $R^2$). The print-ready PDF is at the bottom, free to download.
§1 — Scatter diagrams: direction, form & strength SL 4.4
A scatter diagram plots each pair $(x,y)$ as a point. Before any calculation, describe what you see in three words: direction, form and strength.
Bivariate data:Two variables recorded on each individual, displayed as points on the scatter diagram.
Direction:Positive (points rise to the right), negative (fall to the right), or none.
Form:Linear (points hug a straight line) or non-linear (they follow a curve).
Strength:How tightly the points cluster about that trend — weak, moderate or strong.
A scatter diagram with its least-squares regression line. These points show a strong, positive, linear association; the gold line is the line of best fit, which always passes through the mean point (x̄, ȳ).
NoteDescribe the scatter before you calculate: it tells you whether a linear model (Pearson's $r$ and a straight regression line) is even appropriate. A clear curve means a straight line is the wrong tool.
Trap"Correlation" describes only the linear pattern. A strong curved relationship (say a neat parabola) can still give a correlation coefficient near $0$ — the points genuinely are related, just not by a straight line.
§2 — Pearson's correlation coefficient $r$ SL 4.4
Pearson's product–moment correlation coefficient $r$ puts a single number on the strength and direction of the linear association.
Size = strength:$|r|$ near $1$ is a strong linear fit; near $0$ is weak or none.
On the GDC:Enter the two lists, run 2-variable statistics / LinReg, and read $r$ directly.
$|r|$ (roughly)
Interpretation
$0$
no linear correlation
$\approx 0.25$
weak
$\approx 0.50$
moderate
$\approx 0.75$
strong
$1$
perfect (all points exactly collinear)
NoteThese bands are descriptive, not official IB cut-offs. Always pair the strength word with the direction, e.g. "a strong positive linear correlation."
Trap$r$ measures linear association only. So $r\approx0$ does not mean "no relationship" — it means "no straight-line relationship." Check the scatter for a curve before concluding the variables are unrelated.
§3 — The coefficient of determination $R^2$ SL 4.4
Square the correlation coefficient and you get the coefficient of determination — the single most useful "how good is the model?" number.
Definition:$R^2=r^2$.
Meaning:The proportion (or percentage) of the variation in $y$ that the model explains.
Range:$0\le R^2\le 1$.
TrickRead $R^2$ as a percentage: $R^2=0.92$ means about $92\%$ of the variation in $y$ is explained by the regression on $x$, and the remaining $8\%$ is due to other factors.
Trap$R^2$ is always positive, so it loses the direction that $r$ carries: a strong negative fit and a strong positive fit can share the same $R^2$. To go back from $R^2$ to $r$, take $\pm\sqrt{R^2}$ and choose the sign from the slope of the scatter. And an $R^2$ below $0$ or above $1$ always means a slip.
§4 — Correlation is not causation SL 4.4
This is the interpretation mark examiners love. A strong $r$ shows that two variables move together — it does not prove that one causes the other.
Lurking variable:A hidden third (confounding) variable can drive both $x$ and $y$, manufacturing a correlation with no direct link between them.
Classic example:Ice-cream sales and drowning deaths correlate strongly — but both are driven by a lurking variable, summer temperature; ice cream does not cause drowning.
Trap"There is a strong correlation, therefore $x$ causes $y$" is a guaranteed lost mark. Only a properly controlled experiment — not observational data — can support a causal claim.
NoteTo bank the mark, either name a plausible lurking variable or state that a causal link "cannot be concluded from correlation alone."
§5 — The least-squares regression line of $y$ on $x$ SL 4.4
When the association is linear and reasonably strong, the least-squares regression line of $y$ on $x$ summarises the trend. It is the straight line that minimises the sum of the squared vertical distances from the points.
Equation:$\hat y=ax+b$ — $a$ is the gradient, $b$ the $y$-intercept (GDC LinReg returns both).
Mean point:The line always passes through $(\bar x,\bar y)$, so equivalently $\hat y=\bar y+a(x-\bar x)$.
Gradient (from spread):$a=r\,\dfrac{s_y}{s_x}$ — connects the line back to the correlation.
Intercept:$b=\bar y-a\bar x$ (follows from the line passing through the mean point).
TrickDon't grind the sums by hand — enter the two lists, run LinReg, and the GDC returns $a$, $b$, $r$ and $R^2$ in one screen.
TrapThe line of $y$ on $x$ (for predicting $y$) is not the line of $x$ on $y$. Use $y$ on $x$ whenever you predict $y$ from a given $x$; the two lines differ and only agree when $|r|=1$.
§6 — Interpreting the gradient & intercept SL 4.4
Once you have $\hat y=ax+b$, an exam often asks you to interpret the numbers in context — a pure AI reading-the-answer skill.
Gradient $a$:The estimated change in $y$ for each one-unit increase in $x$ — a rate, carrying units of $y$ per unit of $x$.
A change:A change $\Delta x$ produces $\Delta y=a\,\Delta x$; the intercept plays no part in a change.
Intercept $b$:The predicted value of $y$ when $x=0$.
NoteInterpret with units and context: e.g. "each extra hour of revision raises the predicted score by $a$ marks." A bare number scores nothing.
TrapThe intercept $b$ is only meaningful when $x=0$ sits in or near the data. If $x=0$ is far outside the range, reading $y$ there is extrapolation and can be nonsense.
§7 — Predicting: interpolation vs extrapolation SL 4.4
The whole point of the line is prediction: substitute a value of $x$ into $\hat y=ax+b$. Whether you can trust the answer depends on where that $x$ sits.
Interpolation:Predicting for an $x$ inside the data range — reliable.
Extrapolation:Predicting for an $x$ outside the range — unreliable; the pattern may not continue.
Precondition:Only trust a prediction when $|r|$ (equivalently $R^2$) shows a strong linear fit.
TrapExtrapolation can produce impossible answers — a test score above $100\%$, a negative mass. Always check your $x$ lies within the data before trusting the output.
TrickPredict from the full-accuracy line stored in the GDC, not from $a$ and $b$ chopped to one or two significant figures — small coefficient rounding compounds into a visibly wrong prediction.
§8 — Outliers & prediction error SL 4.4
Two things temper the tidy line: a single stray point can distort it, and even a good line only estimates.
Outlier effect:One outlier can drag the least-squares line and distort $r$; removing a justified outlier and recomputing changes the gradient.
A prediction is an estimate:$\hat y=\bar y+a(x-\bar x)$ gives an approximate value $v_A$, rarely exactly the actual value $v_E$.
TrapIn percentage error the exact (actual, observed) value goes on the bottom — divide by $v_E$, never by your prediction $v_A$.
NoteOnly delete an outlier if there is a reason (a mis-recorded or impossible value). Otherwise report its effect — how much $a$ and $r$ move — rather than silently dropping it.
§9 — Spearman's rank correlation $r_s$ SL 4.10
When the relationship is monotonic (steadily increasing or decreasing) but perhaps curved, or when an outlier would distort Pearson's $r$, switch to Spearman's rank correlation.
Idea:Rank each variable separately, then correlate the ranks rather than the raw values.
Coefficient:$r_s=1-\dfrac{6\sum d^2}{n(n^2-1)}$, where $d$ is the difference in ranks for each individual.
Quick example:With $n=5$ and $\sum d^2=2$: $\;r_s=1-\dfrac{6(2)}{5(25-1)}=1-0.1=0.9$ — a strong positive rank correlation.
TrickSpearman is resistant to outliers and detects any monotonic trend, not just a straight-line one — reach for it when the scatter curves steadily or carries one extreme point.
TrapRank both variables the same way (e.g. $1=$ smallest each time); for tied values, give each the average of the ranks they share. One mis-rank swings $\sum d^2$ a lot.
NoteIf the scatter is clearly curved rather than merely monotonic, a power or exponential model (fitted with the GDC's PwrReg / ExpReg, best $R^2$ wins) usually beats a straight line — see the Non-Linear Modelling & Regression cheatsheet.
§10 — Exam attack plan All sections
Question cue
What to do
Watch for
"Describe the correlation"
State direction + form + strength from the scatter
Give all three words; "correlation" means linear only
"Find the correlation coefficient"
GDC 2-var stats / LinReg → read $r$
Quote the sign; $r$ measures linear association
"What does $R^2$ tell you?"
$R^2=r^2$ = fraction of the variation in $y$ explained
$R^2$ has no sign; recover $r$ as $\pm\sqrt{R^2}$
"Does $x$ cause $y$?"
No — correlation $\neq$ causation; name a lurking variable
Never infer cause from observational data
"Find the regression line"
GDC LinReg → $\hat y=ax+b$
Use $y$ on $x$ to predict $y$; it passes through $(\bar x,\bar y)$
"Interpret the gradient"
$a=$ change in $y$ per $1$-unit rise in $x$ (with units)
Intercept doesn't affect a change: $\Delta y=a\,\Delta x$
"Predict $y$ for a given $x$"
Substitute into the stored full-accuracy line
Interpolation is safe; extrapolation is unreliable
"Curved data or outliers"
Use Spearman's $r_s$ (ranks) or a non-linear model
Rank both the same way; divide by $n(n^2-1)$
Worked Example — Correlation, Regression & Prediction
Question (AI HL Paper 2 style — 8 marks)
A tutor records the weekly revision time $x$ (hours) and the test score $y$ (%) of eight students: $x$: 3, 5, 6, 8, 10, 12, 14, 15 $y$: 45, 52, 54, 63, 68, 74, 80, 85. (a) Use your GDC to find Pearson's correlation coefficient $r$. (b) Describe the correlation. (c) State the coefficient of determination $R^2$ and interpret it. (d) Find the equation of the regression line of $y$ on $x$. (e) Estimate the score of a student who revises for 13 hours, and comment on whether the model should be used to predict the score for 25 hours.
Solution
(a) Enter the eight pairs and run 2-Var Stats / LinReg on the GDC. (M1) This gives $r=0.998$ (3 s.f.). (A1)
(b) Since $r$ is very close to $+1$, the correlation is strong, positive and linear. (A1)
(c) $R^2=r^2=0.996$, so about $99.6\%$ of the variation in test score is explained by revision time. (A1)
(d) From LinReg, $a=3.25$ and $b=35.5$ (3 s.f.), so the line of $y$ on $x$ is $\hat y=3.25x+35.5$. (M1)(A1)(It passes through the mean point $(\bar x,\bar y)=(9.13,\,65.1)$ — a quick sanity check.)
(e) At $x=13$: $\hat y=3.25(13)+35.5=77.75\approx 77.8\%$. (M1)(A1) Since $13$ h lies inside the data range ($3$–$15$ h), this is interpolation and is reliable. Predicting at $x=25$ h gives $\hat y=3.25(25)+35.5=116.75\approx 117\%$ — an impossible score above $100\%$. This is extrapolation far beyond the data, so the model should not be used there.
Examiner's note: keep the units ($\%$) and round to 3 s.f. unless told otherwise. Two marks are routinely lost here — by fitting $x$ on $y$ when the question predicts $y$, and by trusting the extrapolated $117\%$ instead of rejecting it. Remember the line gives an estimate: the actual score of a real 13-hour student will sit a little either side of $77.8\%$.
Common Student Questions
What's the difference between $r$ and $R^2$?
$r$ (Pearson's coefficient) measures both the strength and the direction of a linear association and runs from $-1$ to $1$. $R^2$ (the coefficient of determination) is simply $r^2$; it runs from $0$ to $1$ and gives the proportion of the variation in $y$ that the model explains. Because you square it, $R^2$ is always positive and so loses the direction. For example $r=-0.9$ is a strong negative correlation, while $R^2=0.81$ tells you $81\%$ of the variation is explained. Use $r$ to describe the relationship and $R^2$ to say how well the line fits.
Should I use the $y$-on-$x$ line or the $x$-on-$y$ line?
Use the line whose subject is the quantity you are predicting. To predict $y$ from a given $x$ (the usual exam case — "estimate the score from the revision hours") you need the regression line of $y$ on $x$. The two lines are different — one minimises vertical distances, the other horizontal — and give different predictions, though both pass through the mean point $(\bar x,\bar y)$. They coincide only when $|r|=1$. On the GDC, pick the regression whose response variable matches what the question asks for.
When do I use Spearman's rank instead of Pearson's $r$?
Use Pearson's $r$ when the scatter is roughly a straight line with no wild outliers. Switch to Spearman's $r_s$ when the relationship is monotonic but curved (steadily rising or falling without being straight), when the data are already ranks or ratings, or when an outlier would distort Pearson. Spearman works on the ranks, so it is resistant to outliers and detects any consistently increasing or decreasing trend, not just a linear one.
Why can't I trust a prediction far outside the data (extrapolation)?
Because the linear pattern is only known to hold across the range of data you actually collected. Beyond that range the true relationship may bend, level off, or reverse, so the straight-line estimate becomes unreliable — and can even give impossible values, such as a percentage over $100$ or a negative count. Predicting inside the range (interpolation) is safe; predicting well outside it (extrapolation) should be treated with great caution, or avoided altogether.
Does a strong correlation prove that one variable causes the other?
No. A high $r$ shows only that the two variables vary together. A lurking (confounding) variable may drive both, the association may be coincidental, or the causation could even run the other way. Only a properly designed experiment — not observational data — can establish cause and effect. In an exam, state that a causal conclusion "cannot be drawn from correlation alone," and, where you can, name a plausible lurking variable to secure the mark.
What's NOT in this cheatsheet
This page gives you the formulas and traps for free. The full Photon Academy IB Math AI HL library (enrolled students, or the lifetime resource library) adds:
Notes PDF — every definition, formula and GDC keystroke sequence, with fully worked correlation, regression and Spearman examples.
Tutorial booklet — 25+ AI HL-style questions from scatter-and-correlation fluency to full regression-and-prediction applications.
Tutorial Solutions — mark-scheme-style solutions with M1/A1 annotations and the exact GDC screens to reproduce.
Predicted-paper questions — the bivariate-statistics question types most likely to appear in the next AI HL session.