Free worked solutions · 2026 Edition

IB Maths AI HL Chapter 14: Correlation and regression worked solutions

Worked solutions to the practice questions in Chapter 14 of Photon Guidebook: Mathematics Applications and Interpretation HL for the IB Diploma (2026 Edition). Each solution shows every step with the mark it earns, the way an IB mark scheme does.

  • Chapter 14 of 24
  • Volume 2
  • 25 practice questions
  • 2 Going further
  • Free, no sign-up

Basics

One idea at a time, in the order the chapter teaches them.

Question 1

[2 marks]
Pearson correlation r measures the direction and strength of linear association, with -1\le r\le1. A dataset gives r=-0.87.
Describe its linear correlation and explain the negative sign.
[2]
Show solutionHide solution
Strong negative linear correlation.
A1
As one variable increases, the other tends to decrease.
R1

Final answer

strong negative linear correlation: as one variable increases the other tends to decrease

Question 2

[2 marks]
The points (1,8),(2,6),(3,4),(4,2) all lie on a downward straight line.
State Pearson r without using a GDC and justify.
[2]
Show solutionHide solution
r=-1.
A1
Every point lies exactly on a straight line with negative gradient.
R1

Final answer

r=-1: all the points lie on one straight line with negative gradient

Question 3

[4 marks]
For five printers, x is jobs queued and y is completion delay in minutes.
\begin{array}{c|rrrrr}x&2&5&9&14&18\\\hline y&3.1&4.8&8.4&10.1&13.7\end{array}
Use a GDC to find the least-squares regression line of y on x and Pearson r, giving coefficients to 4 significant figures.
[4]
Show solutionHide solution
Enter the x and paired y lists and select linear regression of y on x.
M1
y=0.6433x+1.845. A1A1
r=0.9909.
A1

Final answer

y=0.6433x+1.845, r=0.9909

Question 4

[3 marks]
A model for packing duration y (minutes) from carton volume x (litres) is y=0.84x+2.6. Observed volumes range from 3 to 17 litres.
Interpret the gradient with units and predict duration for 12 litres.
[3]
Show solutionHide solution
Predicted duration increases by 0.84 minutes for each extra litre.
R1
y=0.84(12)+2.6.
M1
12.68 minutes.
A1

Final answer

0.84 minutes more for each extra litre; 12.68 minutes

Question 5

[3 marks]
A model y=72.6-1.35x predicts remaining fibre length y (m) after x splices. Data used values 5\le x\le24.
Find the model prediction for 40 splices and assess its reliability.
[3]
Show solutionHide solution
y=72.6-1.35(40).
M1
18.6 m.
A1
Unreliable extrapolation: 40 lies outside the observed range.
R1

Final answer

18.6 m; unreliable, because 40 is outside the data range 5 to 24

Question 6

[2 marks]
In a survey, neighbourhood tree coverage and bicycle use have r=0.76.
Explain why this is not sufficient evidence that planting trees causes more bicycle use.
[2]
Show solutionHide solution
Correlation establishes association, not a causal mechanism.
R1
Another variable, such as road design, could affect both.
R1

Final answer

association only; a third variable could affect both

Question 7

[3 marks]
A set of texture score measurements is 27, 18, 33, 27, 41, 27, 12. Use rank 1 for the smallest measurement and average ranks for ties.
(a) Find the ranks in the listed order.
[2]
(b) Explain the rank assigned to the first repeated measurement.
[1]
Show solutionHide solution
(a) Order the observations and average the occupied positions for each tied group.
M1
The rank list is 4, 2, 6, 4, 7, 4, 1.
A1
(b) The three scores of 27 occupy positions 3, 4 and 5, so each receives (3+4+5)/3=4.
R1

Final answer

4, 2, 6, 4, 7, 4, 1; the three values of 27 share positions 3 to 5

Question 8

[4 marks]
A survey records training hours (X) and fault counts (Y) for the same subjects.
\begin{array}{c|rrrrr}X&14&22&31&37&48\\Y&61&58&47&53&39\end{array}
Use rank 1 for the lowest value in each list.
(a) Write both rank lists, using average ranks for any ties.
[2]
(b) Use Pearson correlation on the two rank lists to find r_s to 3 significant figures.
[2]
Show solutionHide solution
(a) R_X=(1, 2, 3, 4, 5).
A1
R_Y=(5, 4, 2, 3, 1).
A1
(b) Enter the rank lists as paired GDC data and calculate their Pearson correlation.
M1
r_s=-0.900.
A1

Final answer

ranks of X: 1 to 5; ranks of Y: 5, 4, 2, 3, 1; r_s=-0.900

Question 9

[4 marks]
Two inspectors give the following ranks to the same objects. Neither list has ties.
\begin{array}{c|rrrrrr}R_A&1&2&3&4&5&6\\R_B&6&4&5&2&3&1\end{array}
You may use r_s=1-\frac{6\sum d^2}{n(n^2-1)}, where d=R_A-R_B.
(a) Find \sum d^2.
[2]
(b) Calculate r_s to 3 significant figures.
[2]
Show solutionHide solution
(a) The differences are -5, -2, -2, 2, 2, 5.
M1
\sum d^2=66.
A1
(b) r_s=1-\frac{6(66)}{6(35)}.
M1
r_s=-0.886.
A1

Final answer

\sum d^2=66; r_s=-0.886

Question 10

[3 marks]
A process produces an overall increasing scatter plot with some small reversals and a clearly curved pattern. GDC output is r=0.71 and r_s=0.96.
(a) Explain why Spearman describes the ordering more closely.
[2]
(b) State what Pearson measures in this comparison.
[1]
Show solutionHide solution
(a) Spearman compares ranks.
A1
A consistently increasing ordering can have strong rank association even when the pattern is curved.
R1
(b) Pearson measures the strength of linear association between the original numerical values.
R1

Final answer

Spearman follows the order along a curve; Pearson measures closeness to a straight line

Tutorial

Exam-style questions on each question type, with the marks the IB would give.

Question 11

[5 marks]
A courier company records the mass, x kg, of seven parcels and the delivery fee, y dollars, charged for each.
\begin{array}{@{}l@{\,}|@{\,}*{7}{c@{\;}}@{}} x & \text{1.5} & \text{2.0} & \text{3.5} & \text{4.0} & \text{6.5} & \text{8.0} & \text{9.5} \\ y & \text{7.20} & \text{7.40} & \text{9.90} & \text{9.60} & \text{12.10} & \text{14.80} & \text{15.70} \\ \end{array}
(a) Find the value of r for these data.
[2]
A branch in another country records the same parcels with the mass in pounds, m, and the fee in cents, c.
\begin{array}{@{}l@{\,}|@{\,}*{7}{c@{\;}}@{}} m & \text{3.31} & \text{4.41} & \text{7.72} & \text{8.82} & \text{14.33} & \text{17.64} & \text{20.94} \\ c & \text{720} & \text{740} & \text{990} & \text{960} & \text{1210} & \text{1480} & \text{1570} \\ \end{array}
(b) Find the value of r for m and c.
[1]
(c) Explain why your answers to (a) and (b) are the same, to three significant figures.
[2]
Show solutionHide solution
(a) GDC linear regression on x and y: r=0.99202\ldots, so r=0.992.
[2]
(b) GDC linear regression on m and c: r=0.99205\ldots=0.992.
[1]
(c) Changing units is a linear change of each variable (m\approx2.2046x and c=100y), which stretches the scales but leaves the pattern of the points unchanged.
[1]
r measures the strength of the linear association, a pure number with no units, so it is unaffected by rescaling (any small difference comes from rounding the converted data).
[1]

Final answer

  • (a) r=0.992
  • (b) r=0.992
  • (c) a change of units does not change the shape of the scatter, so r is unchanged

Question 12

[4 marks]
A conservation group studies mangrove saplings. The regression line of h on t for one plantation is h = 3.2t + 14.5, where h is the height of a sapling in centimetres and t is the number of months since it was planted. The values of t in the data range from 2 to 18, and the mean of the t values is \bar t = 10.
(a) Interpret the gradient of the line in the context of the question.
[1]
(b) Interpret the value 14.5, and state whether it is a sensible value in this context.
[2]
(c) Find the mean height \bar h of the saplings in the data.
[1]
Show solutionHide solution
(a) Each extra month since planting is associated with an increase in height of about 3.2 cm.
[1]
(b) It is the predicted height, 14.5 cm, of a sapling at t=0, that is, at the moment of planting.
[1]
It is a sensible value here: a newly planted sapling can easily be about 15 cm tall (and t=0 is realistic).
[1]
(c) The regression line passes through (\bar t,\bar h): \bar h=3.2(10)+14.5=46.5 cm.
[1]

Final answer

  • (a) 3.2 cm more height for each extra month
  • (b) height at planting, 14.5 cm, which is sensible
  • (c) \bar h=46.5 cm

Question 13

[7 marks]
Ravi is a delivery rider on an electric bicycle. On six trips he records the number of parcels carried, x, and the percentage of battery charge used, y\%, on the same route. One value, k, is missing.
\begin{array}{@{}l@{\,}|@{\,}*{6}{c@{\;}}@{}} x \text{(parcels)} & \text{2} & \text{4} & \text{5} & \text{7} & \text{9} & \text{11} \\ y \text{(\%)} & \text{11.6} & \text{9.4} & \text{13.4} & k & \text{27.6} & \text{27.9} \\ \end{array}
The regression line of y on x for all six rides is exactly y=2.3x+3.8.
(a) Find the mean of the six x values.
[1]
(b) Hence find the value of k.
[3]
(c) Find the value of the correlation coefficient r for the six rides.
[1]
(d) Use the line to estimate the percentage of charge used when Ravi carries 6 parcels.
[2]
Show solutionHide solution
(a) \bar x=\dfrac{2+4+5+7+9+11}{6}=\dfrac{38}{6}=6.33 (exactly \dfrac{19}{3}).
[1]
(b) The regression line passes through (\bar x,\bar y), so \bar y=2.3\left(\dfrac{19}{3}\right)+3.8=18.3667\ldots
[1]
The six y values total 6\bar y=6\times18.3667\ldots=110.2.
[1]
The five known values total 11.6+9.4+13.4+27.6+27.9=89.9, so k=110.2-89.9=\textbf{20.3}.
[1]
(c) GDC (with k=20.3): r=0.94077\ldots=0.941.
[1]
(d) y=2.3(6)+3.8=17.6\% of the battery.
[2]

Final answer

  • (a) 6.33
  • (b) k=20.3
  • (c) 0.941
  • (d) 17.6%

Question 14

[7 marks]
A laboratory will accept a new temperature sensor only if the correlation coefficient between the sensor's readings and the readings of a reference thermometer is greater than 0.97. Two sensors, A and B, are tested at six temperatures. All readings are in ^\circC.
\begin{array}{l|cccccc} \text{Reference,} x & \text{10} & \text{20} & \text{30} & \text{40} & \text{50} & \text{60} \\ \text{Sensor A,} y_A & \text{14} & \text{17} & \text{33} & \text{38} & \text{55} & \text{57} \\ \text{Sensor B,} y_B & \text{12} & \text{24} & \text{26} & \text{47} & \text{43} & \text{66} \\ \end{array}
(a) Find the correlation coefficient between the reference readings and the readings of
(i) sensor A; (ii) sensor B.
[2]
(b) State, with a reason, which sensors the laboratory should accept.
[2]
(c) For the accepted sensor, find the regression line of its reading on the reference reading, and use it to estimate the sensor's reading when the true temperature is 35\,{}^\circC.
[3]
Show solutionHide solution
(a) GDC linear regression (reference in one list, sensor in the other):
(i) r_A=0.98001\ldots=0.980.
[1]
(ii) r_B=0.95692\ldots=0.957.
[1]
(b) r_A=0.980>0.97, so sensor A meets the condition; r_B=0.957<0.97, so sensor B does not.
[1]
Accept sensor A only (sensor B is rejected).
[1]
(c) Regression of y_A on x: \textbf{y = 0.954x + 2.27} (with a=0.95429\ldots, b=2.26667\ldots).
[2]
At x=35: y_A=0.95429(35)+2.26667=35.667\ldots\approx\textbf{35.7}\,{}^\circC.
[1]

Final answer

  • (a) 0.980 and 0.957
  • (b) accept sensor A only
  • (c) y=0.954x+2.27; 35.7 ^\circC

Question 15

[8 marks]
A phone manufacturer tests the battery while a video plays continuously. For seven phones of the same model, the table shows the time, t hours, for which the video has played and the battery charge remaining, C\,\%.
\begin{array}{@{}l@{\,}|@{\,}*{7}{c@{\;}}@{}} t \text{(hours)} & \text{0.5} & \text{1} & \text{1.5} & \text{2} & \text{2.5} & \text{3} & \text{3.5} \\ C \text{(\%)} & \text{92} & \text{85} & \text{78} & \text{73} & \text{64} & \text{60} & \text{50} \\ \end{array}
(a) Find r and the equation of the regression line of C on t.
[3]
(b) Interpret the gradient and the intercept of the line in this context.
[2]
(c) Use your line to predict the charge remaining after 2.75 hours.
[1]
The manufacturer advertises, “Plays video for 8 hours.” A colleague uses the regression line to find the value of t at which the predicted charge reaches 0\,\%.
(d) Find this value of t, and comment on whether it supports the advertisement.
[2]
Show solutionHide solution
(a) GDC: r=-0.99686\ldots=-0.997,
[1]
a=-13.5714\ldots,\ b=98.8571\ldots, so \textbf{C=-13.6t+98.9}.
[2]
(b) Gradient: each extra hour of playing is associated with about 13.6 percentage points less charge.
[1]
Intercept: the model predicts about 98.9% charge at t=0 (a fully charged battery would read 100%, so this is close to sensible).
[1]
(c) C=-13.5714(2.75)+98.8571=61.536\ldots\approx\textbf{61.5}\%.
[1]
(d) Solve -13.5714t+98.8571=0 (GDC solver or rearrange): t=7.284\ldots\approx\textbf{7.28} hours.
[1]
This is well beyond the data (maximum 3.5 hours): it is extrapolation, so it cannot be relied upon, and the model does not establish the advertised 8 hours (batteries often discharge faster or slower as they run down).
[1]

Final answer

  • (a) r=-0.997, C=-13.6t+98.9
  • (b) 13.6 points of charge per hour; 98.9% at the start
  • (c) 61.5%
  • (d) 7.28 h, extrapolation

Question 16

[6 marks]
(a) Hana models the number of visitors, V, to a botanic garden on a day with s hours of sunshine, using data for which 0\le s\le10. Her regression line is V=38s+120 and the correlation coefficient is r=0.58.
(i) Estimate the number of visitors on a day with 6 hours of sunshine.
[1]
(ii) Comment on the reliability of your estimate.
[2]
(b) Jorge models the time, T minutes, for a pool heater to raise the water by 2\,{}^\circC when the pool is at temperature w\,{}^\circC, using data for 18\le w\le30. His regression line is T=-4.1w+190 and r=-0.97.
(i) Use his line to estimate T when w=40.
[1]
(ii) Comment on the reliability of this estimate.
[2]
Show solutionHide solution
(a) (i) V=38(6)+120=348 visitors.
[1]
(ii) s=6 is inside the data range, so this is interpolation, which is usually reliable.
[1]
However r=0.58 is only a moderate correlation, so the points are widely scattered about the line and the estimate is not very reliable.
[1]
(b) (i) T=-4.1(40)+190=26 minutes.
[1]
(ii) w=40 is far outside the range 18 to 30, so this is extrapolation.
[1]
Although |r|=0.97 is very strong, there is no evidence that the linear relationship continues to 40\,{}^\circC, so the estimate is unreliable (the line would also give T=0 at about 46\,{}^\circC, which is not physically sensible).
[1]

Final answer

  • (a)(i) 348
  • (ii) moderate r, so only a rough estimate
  • (b)(i) 26 minutes
  • (ii) extrapolation, unreliable

Question 17

[4 marks]
Seven riders each deliver the same parcel across a city. Their times, in minutes, are 24.5,\; 22.0,\; 27.3,\; 22.0,\; 31.8,\; 25.1,\; 29.0.
(a) Rank the seven times, giving rank 1 to the shortest time.
[2]
(b) Explain how you dealt with the repeated value.
[1]
(c) Three other values in a different data set are equal and would occupy positions 4, 5 and 6. Write down the rank each of them receives.
[1]
Show solutionHide solution
(a) Order from shortest: 22.0,\ 22.0,\ 24.5,\ 25.1,\ 27.3,\ 29.0,\ 31.8.
[1]
\begin{array}{l|ccccccc} \text{time} & \text{24.5} & \text{22.0} & \text{27.3} & \text{22.0} & \text{31.8} & \text{25.1} & \text{29.0} \\ \text{rank} & \text{3} & \text{1.5} & \text{5} & \text{1.5} & \text{7} & \text{4} & \text{6} \\ \end{array}
All seven correct.
[1]
(b) The two values of 22.0 would occupy ranks 1 and 2, so each is given the average rank \dfrac{1+2}{2}=1.5; the next value then has rank 3.
[1]
(c) \dfrac{4+5+6}{3}=5, so each receives rank 5.
[1]

Final answer

  • (a) 3, 1.5, 5, 1.5, 7, 4, 6
  • (b) tied times share the mean of ranks 1 and 2
  • (c) rank 5

Question 18

[5 marks]
Two jurors at a film festival each score eight short films out of 10.
\begin{array}{@{}l@{\,}|@{\,}*{8}{c@{\;}}@{}} \text{Film} & \text{1} & \text{2} & \text{3} & \text{4} & \text{5} & \text{6} & \text{7} & \text{8} \\ \text{Juror 1} & \text{7.5} & \text{6.0} & \text{8.5} & \text{6.0} & \text{9.0} & \text{5.5} & \text{7.0} & \text{8.0} \\ \text{Juror 2} & \text{7.0} & \text{6.5} & \text{9.0} & \text{5.5} & \text{8.5} & \text{6.0} & \text{7.5} & \text{8.0} \\ \end{array}
(a) Rank each juror's scores (rank 1 for the highest, average ranks for ties).
[2]
(b) Calculate Spearman's rank correlation coefficient.
[1]
(c) Comment on the extent to which the jurors agree, and state one advantage of using r_s rather than r for judges' scores.
[2]
Show solutionHide solution
(a)
\begin{array}{l|cccccccc} \text{Film} & \text{1} & \text{2} & \text{3} & \text{4} & \text{5} & \text{6} & \text{7} & \text{8} \\ \text{Juror 1} & \text{4} & \text{6.5} & \text{2} & \text{6.5} & \text{1} & \text{8} & \text{5} & \text{3} \\ \text{Juror 2} & \text{5} & \text{6} & \text{1} & \text{8} & \text{2} & \text{7} & \text{4} & \text{3} \\ \end{array}
[2]
(b) Regression on the two lists of ranks: r_s=0.9102\ldots=\textbf{0.910}.
[1]
(c) r_s=0.910 is a very strong positive association: the jurors largely agree on the order of the films.
[1]
Judges' scores are not on an exactly comparable scale (one juror may be harsher), and r_s depends only on the order, not on the size of the scores.
[1]

Final answer

  • (a) Juror 1: 4, 6.5, 2, 6.5, 1, 8, 5, 3; Juror 2: 5, 6, 1, 8, 2, 7, 4, 3
  • (b) r_s=0.910
  • (c) strong agreement; ranks suit judges' scores

Question 19

[5 marks]
A fitness blog reports that, for 12 members of a gym, the regression line of weight lost, w kg, on the number of gym visits in a month, v, is w=0.21v-0.4, with r=0.55. The blog concludes: “Every extra visit causes you to lose 0.21 kg.”
(a) Interpret the gradient 0.21 correctly, without implying causation.
[1]
(b) State two reasons why the blog's conclusion is not justified by these data.
[2]
(c) Describe a study design that would give better evidence of a causal effect.
[2]
Show solutionHide solution
(a) Members who made one more visit lost, on average, about 0.21 kg more (an association).
[1]
(b) The correlation is only moderate (r=0.55) and the sample is small (12 members), so the line is not reliable.
[1]
Correlation is not causation: members who visit more may also eat differently or be more motivated (confounding variables), so the visits need not cause the loss.
[1]
(c) Randomly assign volunteers to different numbers of visits per month (with the same diet advice) for several months and compare their weight loss, so that other factors are spread evenly between the groups.
[2]

Final answer

  • (a) association: 0.21 kg more per extra visit
  • (b) moderate r and small sample; other factors
  • (c) a randomised experiment

Question 20

[9 marks]
An allergy clinic records, on seven days, the hours of sunshine, x, and the pollen count, y (grains per cubic metre).
\begin{array}{l|ccccccc} x & \text{3} & \text{5} & \text{6} & \text{8} & \text{9} & \text{11} & \text{12} \\ y & \text{40} & \text{58} & \text{47} & \text{66} & \text{55} & \text{68} & \text{60} \\ \end{array}
It may be assumed that the data come from a bivariate normal distribution, with population correlation coefficient \rho. The clinic tests H_0:\rho=0 against H_1:\rho>0 at the 5% significance level.
(a) Find the sample correlation coefficient r.
[1]
(b) Use your GDC (linear regression t-test, or equivalent) to find the p-value, and state the conclusion in context.
[3]
The clinic then decides it should have tested H_0:\rho=0 against H_1:\rho\ne0.
(c) Find the new p-value and state the conclusion at the 5% level. Explain why the conclusion differs from that in (b).
[3]
(d) A second clinic obtains the same value of r from only 5 days of data. Find the p-value for the one-tailed test, and explain what this shows about the effect of sample size.
[2]
Show solutionHide solution
(a) r=0.73508\ldots=0.735.
[1]
(b) GDC: t=2.42 with 5 degrees of freedom, p=0.0299 (one-tailed).
[2]
p=0.0299<0.05: reject H_0; there is sufficient evidence at the 5% level of a positive correlation between hours of sunshine and pollen count.
[1]
(c) Two-tailed: p=2\times0.0299=0.0598.
[1]
0.0598>0.05: do not reject H_0; insufficient evidence at the 5% level of a correlation.
[1]
The two-tailed test splits the 5% between both tails, so a given sample has to be more extreme to be significant; the one-tailed test uses a prior expectation of a positive correlation.
[1]
(d) With n=5 (3 degrees of freedom): t=1.88, p=0.0785.
[1]
This is above 0.05, so the second clinic cannot reject H_0 although r is the same as for n=7 (p=0.0299): the same r is weaker evidence with fewer points, so small samples need a larger |r| to be significant.
[1]

Final answer

  • (a) 0.735
  • (b) p=0.0299, reject H_0
  • (c) p=0.0598, do not reject
  • (d) p=0.0785

Mastery

Full exam questions that mix question types, at Paper 1 and Paper 2 standard.

Question 21

[11 marks]
A small business tracks its monthly advertising spend x (in thousands of dollars) and its monthly revenue y (in thousands of dollars) over seven months.
x ($000)2468101214
y ($000)18252936414450
(a) (i) Use your GDC to find the Pearson product-moment correlation coefficient r.
(ii) Describe the correlation between advertising spend and revenue.
[3]
(b) Find the equation of the least-squares regression line of y on x, giving coefficients to 3 significant figures.
[2]
(c) Use your line to estimate the revenue in a month when $9000 is spent on advertising.
[2]
(d) The owner argues that spending $0 on advertising would still give revenue equal to the y-intercept of the line. State, with a reason, whether this is a reliable estimate.
[2]
(e) The owner plans to spend $50 000 next month and the line predicts revenue of about $144 000. Comment on the reliability of this prediction.
[2]
Show solutionHide solution
(a) (i) Using GDC, r = 0.996 (3 s.f.).
(ii) Since r is positive and very close to 1, there is a strong positive correlation between advertising spend and revenue.
[3]
(b) Using GDC, y = 2.61x + 13.9.
[2]
(c) Here x=9 (thousand dollars): y = 2.61(9) + 13.9 \approx 37.3, so about $37 300.
[2]
(d) The y-intercept 13.9 corresponds to x=0, which lies just outside the data range (x from 2 to 14), so it is an extrapolation and only a rough estimate; it may not be reliable.
[2]
(e) x=50 is far outside the data range (2 to 14), so predicting revenue there is extrapolation and is unreliable; the linear trend may not continue at such high spending.
[2]

Final answer

  • (a) r=0.996
  • (b) y=2.61x+13.9
  • (c) about USD 37 300
  • (d), (e) extrapolation

Question 22

[6 marks]
A meteorology student collects data on seven regions, recording the annual rainfall x (in mm) and the average crop yield y (in tonnes per hectare).
x (mm)200300400500600700800
y1.82.63.33.94.24.13.6
(a) Use your GDC to find the Pearson product-moment correlation coefficient r.
[2]
(b) The value of r is only moderately close to 1. By describing the pattern in the table, explain why a straight-line model does not fit these data well.
[2]
(c) Suggest, with a reason, why yield falls when rainfall becomes very high.
[2]
Show solutionHide solution
(a) Using GDC, r = 0.818 (3 s.f.).
[2]
(b) The yield rises as rainfall increases up to about 600 mm, then falls for higher rainfall. This shows a curved (roughly parabolic) relationship, not a straight line, so a linear model fits poorly and r is only moderate.
[2]
(c) At very high rainfall the ground may become waterlogged, which harms the crop, so yield decreases.
[2]

Final answer

  • (a) r=0.818
  • (b) yield rises then falls: the relationship is curved
  • (c) waterlogging

Question 23

[8 marks]
Five readings of a variable y are taken at x=1,2,3,4,5. The last reading, k, is missing.
\begin{array}{l|ccccc} x & \text{1} & \text{2} & \text{3} & \text{4} & \text{5} \\ y & \text{4} & \text{7} & \text{9} & \text{14} & k \\ \end{array}
(a) The regression line of y on x has gradient 2.5. Find the value of k.
[3]
(b) For this value of k, find r and the equation of the regression line.
[2]
(c) By considering r as a function of k (for example, by graphing it on your GDC), find the value of k for which r is greatest. Give your answer to 3 significant figures.
[2]
(d) Explain why this value of k does not mean that the data lie on a straight line.
[1]
Show solutionHide solution
(a) The gradient depends on k: with \bar x=3, the gradient is \dfrac{\sum(x-\bar x)y}{\sum(x-\bar x)^2}=\dfrac{-2(4)-1(7)+0+1(14)+2k}{10}.
[2]
Setting \dfrac{2k-1}{10}=2.5 gives k=\textbf{13}.
[1]
(b) GDC with k=13: r=0.95036\ldots=0.950; \textbf{y = 2.50x + 1.90}.
[2]
(c) Enter r(k) using a list formula (or graph the regression command with the parameter) and find the maximum on the graph: k=16.8 (r=0.9915).
[2]
(d) The largest possible value of r is still below 1 (0.9915), because the first four points are not exactly collinear; changing one value cannot remove their scatter about a line.
[1]

Final answer

  • (a) k=13
  • (b) r=0.950, y=2.50x+1.90
  • (c) k=16.8
  • (d) r=0.9915, not 1

Question 24

[12 marks]
A taxi company in Lisbon records the distance, d km, and the fare, F EUR, for seven trips.
d235791215
F6.407.8010.6012.2015.8018.6021.20
Marta models the fares with the straight line through the points (3, 7.80) and (12, 18.60).
(a) Find the gradient of Marta's line.
[2]
(b) Interpret the gradient in context.
[1]
(c) Find the equation of Marta's line.
[1]
(d) State what the constant term in Marta's equation represents.
[1]
(e) Find the mean point (\bar d, \bar F) of the seven trips.
[2]
(f) Find the equation of the regression line of F on d, and the value of r.
[2]
(g) Estimate the fare for an 8 km trip using each model.
[2]
(h) Comment on using the regression line to estimate the fare for a trip of 40 km.
[1]
Show solutionHide solution
(a) \frac{18.60-7.80}{12-3} M1 =1.2 A1 (b) The fare rises by EUR 1.20 for each extra kilometre R1 (c) c=7.80-1.2(3)=4.2, so F=1.2d+4.2 A1 (d) A fixed charge of EUR 4.20 at the start of every trip R1 (e) \bar d=\frac{53}{7}=7.57 M1 \bar F=\frac{92.6}{7}=13.2, so (7.57, 13.2) A1 (f) F=1.16d+4.48 A1 r=0.995 A1 (g) Marta: 1.2(8)+4.2= EUR 13.80 A1 Regression: 1.156(8)+4.476= EUR 13.72 A1 (h) 40 km is far outside the data (2 km to 15 km): extrapolation, so the estimate is unreliable
R1

Final answer

  • (a) 1.2
  • (b) EUR 1.20 per kilometre
  • (c) F=1.2d+4.2
  • (d) a fixed charge of EUR 4.20
  • (e) (7.57,\ 13.2)
  • (f) F=1.16d+4.48, r=0.995
  • (g) EUR 13.80 and EUR 13.72
  • (h) extrapolation

Question 25

[16 marks]
A running club records, for nine runners A to I, the mean weekly training distance, x km, over three months and each runner's time, y minutes, in a marathon at the end of that time.
RunnerABCDEFGHI
x (km)324538605245702858
y (min)262231248205222236198271290
(a) Rank the distances and the times, giving rank 1 to the largest value in each row, and find Spearman's rank correlation coefficient, r_s.
[4]
(b) Find Pearson's correlation coefficient, r, for the nine runners.
[1]
Runner I ran the marathon with an ankle injury.
(c) Explain why r_s is less affected than r by runner I's result.
[2]
(d) For the other eight runners, use your GDC to find the regression line of y on x.
[2]
(e) Interpret the gradient of this line in context.
[1]
(f) Use the line to estimate the marathon time of a runner who trains 50 km a week.
[1]
(g) Assume that the data for the other eight runners come from a bivariate normal distribution. Test at the 1% significance level whether there is a negative correlation between training distance and marathon time. State the hypotheses, the p-value and the conclusion.
[3]
(h) A coach uses the line from part (d) to predict the time of a runner who trains 110 km a week. Comment on this.
[1]
(i) Runner C's distance is checked and changed from 38 km to 39 km. Explain why your value of r_s in part (a) does not change.
[1]
Show solutionHide solution
(a) Distance ranks A 8, B 5.5, C 7, D 2, E 4, F 5.5, G 1, H 9, I 3 A1 Time ranks A 3, B 6, C 4, D 8, E 7, F 5, G 9, H 2, I 1 A1 Pearson's r of the two lists of ranks M1 r_s=-0.644 A1 (b) r=-0.575 A1 (c) Runner I is an extreme value: in r the large time, far from the line, pulls r towards 0 R1 In r_s runner I is simply rank 1 for time, whatever the size of the time R1 (d) y=-1.80x+317 A1A1 (e) Each extra kilometre of weekly training goes with a marathon about 1.80 minutes faster R1 (f) -1.80211(50)+317.472=227 minutes A1 (g) H_0: \rho=0, H_1: \rho<0 A1 p=2.54\times10^{-6} A1 p<0.01: reject H_0; there is strong evidence of a negative correlation between training distance and marathon time R1 (h) 110 km is far above the largest distance (70 km): extrapolation, so the estimate is unreliable R1 (i) 39 km is still between 45 km (B and F) and 32 km (A), so C is still 7th and no rank changes
R1

Final answer

  • (a) r_s=-0.644
  • (b) r=-0.575
  • (c) ranks resist an extreme value
  • (d) y=-1.80x+317
  • (e) 1.80 minutes faster per extra kilometre
  • (f) 227 minutes
  • (g) p=2.54\times10^{-6}, reject H_0
  • (h) extrapolation
  • (i) C is still 7th

Going further

Beyond the syllabus: the worked examples and investigations of the chapter's Going further pages.

G1 The best line is the vertex of a quadratic

G1 Worked example

[8 marks]
Tariq hangs four loads, x kg, from a spring and measures its extension, y mm: (1,3), (2,4), (3,8), (4,9).
(a) Find the mean point.
[1]
(b) For a line y=6+m(x-2.5), show that the total of the squared vertical gaps is S(m)=5m^2-22m+26.
[3]
(c) Find the value of m that makes S(m) as small as possible, and the smallest value of S(m).
[3]
(d) Write down the equation of the line of best fit and check it with your GDC.
[1]
Show solutionHide solution
(a) \bar x=\frac{10}{4}=2.5, \bar y=\frac{24}{4}=6, so (2.5,\,6) A1 (b) Each vertical gap is (y-6)-m(x-2.5) M1 \sum(y-6)^2=9+4+4+9=26, \sum(x-2.5)(y-6)=4.5+1+1+4.5=11, \sum(x-2.5)^2=5 A1 S(m)=26-2(11)m+5m^2=5m^2-22m+26 A1AG (c) S'(m)=10m-22=0 (or the vertex at m=-\frac{-22}{2(5)}) M1 m=2.2 A1 S(2.2)=5(4.84)-22(2.2)+26=1.8 A1 (d) y=6+2.2(x-2.5)=2.2x+0.5, and the GDC regression gives a=2.2, b=0.5
A1

Final answer

  • (a) (2.5,\,6)
  • (c) m=2.2, S=1.8
  • (d) y=2.2x+0.5

G2 The shortcut for r_s is Pearson's r in disguise

G2 Investigation

[19 marks]
Use \sum_{k=1}^{n}k=\frac{n(n+1)}{2} and \sum_{k=1}^{n}k^2=\frac{n(n+1)(2n+1)}{6}.
(a) Show that the mean of the ranks 1,2,\ldots,n is \frac{n+1}{2}, and that \sum_{k=1}^{n}\left(k-\frac{n+1}{2}\right)^2=\frac{n(n^2-1)}{12}.
[5]
(b) Two judges rank the same n items with no ties. Judge 1 gives item i rank p_i and judge 2 gives it rank q_i, and d_i=p_i-q_i. Show that \sum p_iq_i=\sum_{k=1}^{n}k^2-\frac12\sum d_i^2.
[2]
(c) Hence show that Pearson's correlation coefficient of the two lists of ranks equals 1-\frac{6\sum d_i^2}{n(n^2-1)}.
[4]
(d) For n=6, judge 2 reverses judge 1's order exactly. Find \sum d_i^2 and verify that the formula gives -1.
[3]
(e) The ranks 1,2,3,4 are paired with the ranks 1,\,2.5,\,2.5,\,4. Find \sum d^2, the value given by the shortcut, and Pearson's r of the two lists from your GDC. Use part (a) to explain why the shortcut is not exact when there are ties.
[5]
Show solutionHide solution
(a) Mean =\frac1n\cdot\frac{n(n+1)}{2}=\frac{n+1}{2} M1A1 With m=\frac{n+1}{2}, \sum(k-m)^2=\sum k^2-nm^2 M1 =\frac{n(n+1)(2n+1)}{6}-\frac{n(n+1)^2}{4} A1 =\frac{n(n+1)\left[2(2n+1)-3(n+1)\right]}{12}=\frac{n(n^2-1)}{12} A1AG (b) d_i^2=p_i^2+q_i^2-2p_iq_i, and each of \sum p_i^2, \sum q_i^2 equals \sum k^2 because the ranks are 1,\ldots,n in some order M1 So \sum d_i^2=2\sum k^2-2\sum p_iq_i, giving the result A1 (c) S_{pq}=\sum p_iq_i-nm^2=\sum k^2-nm^2-\frac12\sum d_i^2=\frac{n(n^2-1)}{12}-\frac12\sum d_i^2 M1A1 S_{pp}=S_{qq}=\frac{n(n^2-1)}{12}, so \sqrt{S_{pp}S_{qq}}=\frac{n(n^2-1)}{12} A1 r=\frac{S_{pq}}{\sqrt{S_{pp}S_{qq}}}=1-\frac{6\sum d_i^2}{n(n^2-1)} A1AG (d) d=5,3,1,-1,-3,-5, so \sum d^2=25+9+1+1+9+25=70 A1 1-\frac{6(70)}{6(35)} M1 =1-2=-1 A1 (e) d=0,-0.5,0.5,0, so \sum d^2=0.5 A1 Shortcut: 1-\frac{6(0.5)}{4(15)}=0.95 A1 GDC on the two lists: r=0.949 A1 For the tied list \sum(q-2.5)^2=4.5, which is less than \frac{n(n^2-1)}{12}=5 M1 So the denominator \sqrt{S_{pp}S_{qq}} in (c) is smaller than the value the shortcut assumes, and the shortcut is inexact
R1

Final answer

  • (d) \sum d^2=70
  • (e) \sum d^2=0.5, shortcut 0.95, Pearson 0.949

From the book

Photon Guidebook: Mathematics Applications and Interpretation HL for the IB Diploma

Chapter 14 teaches correlation and regression from the basics to full exam questions: how the IB asks it, every question type with a marked example, and these practice questions in three steps.

About the book