All revision notes topics

Product moment and Spearman's rank correlationEdexcel A-Level Further Maths: Revision notes

Section 1

The product moment correlation coefficient

The product moment correlation coefficient (PMCC) rr measures the strength of linear correlation between two variables, with −1≤r≤1-1\le r\le1. From summary statistics, Sxx=∑x2−(∑x)2n,Syy=∑y2−(∑y)2n,Sxy=∑xy−∑x∑yn,S_{xx}=\sum x^2-\frac{(\sum x)^2}{n},\quad S_{yy}=\sum y^2-\frac{(\sum y)^2}{n},\quad S_{xy}=\sum xy-\frac{\sum x\sum y}{n}, r=SxySxxSyy.r=\frac{S_{xy}}{\sqrt{S_{xx}S_{yy}}}. Example: Sxx=62.5S_{xx}=62.5, Syy=40S_{yy}=40, Sxy=−45S_{xy}=-45 give r=−452500=−0.9r=\frac{-45}{\sqrt{2500}}=-0.9: strong negative linear correlation. Values near ±1\pm1 show strong correlation and values near 00 show little linear correlation.

Key termsproduct moment correlation coefficient$S_{xy}$
Common mistake

Interpreting a correlation as causation. Describe it as an association, in context.

Section 2

Conditions and the effect of coding

The PMCC is only meaningful when the data come from a population with a bivariate normal distribution, so the scatter diagram should look roughly elliptical, with no clear curve and no outlier. It is a measure of linear correlation only. Coding (a linear change such as x′=ax+bx'=ax+b, y′=cy+dy'=cy+d) does not change the size of rr. If aa and cc have the same sign, rr is unchanged; if exactly one is negative, rr changes sign. So with Sxx=62.5S_{xx}=62.5, r=−0.9r=-0.9 between xx and yy becomes +0.9+0.9 between xx and w=100−2yw=100-2y.

Key termsbivariate normal distributioncoding
Exam tip

For coding questions, look only at the signs of the multipliers: the numbers added or subtracted never matter.

Section 3

Spearman's rank correlation coefficient

Spearman's rank correlation coefficient rsr_s measures how well the relationship between two variables can be described by a monotonic (always increasing or always decreasing) function. It is used when data are ranks, or when the data are not bivariate normal or the relationship is monotonic but not linear. Rank each variable, find the difference dd in ranks for each pair, then rs=1−6∑d2n(n2−1).r_s=1-\frac{6\sum d^2}{n(n^2-1)}. Example: n=6n=6, ∑d2=6\sum d^2=6 gives rs=1−36210=0.829r_s=1-\frac{36}{210}=0.829. Spearman's coefficient is less affected by outliers than the PMCC.

Key termsSpearman's rank correlation coefficientmonotonicrank
Common mistake

Subtracting from 6∑d26\sum d^2 instead of from 11, or using n(n2+1)n(n^2+1) in the denominator.

Section 4

Ties in ranks

When two or more values are equal, give each the mean of the ranks they would have occupied. For example, two scores in joint 3rd and 4th place both get rank 3.53.5. The next value continues at rank 55. The formula for rsr_s assumes there are no ties, so with ties it is only an approximation (the exact value is the PMCC of the ranks). Example: mathematics scores 56,61,61,70,48,75,6656, 61, 61, 70, 48, 75, 66 have ranks 2,3.5,3.5,6,1,7,52, 3.5, 3.5, 6, 1, 7, 5. With physics ranks 3,4,2,6,1,7,53, 4, 2, 6, 1, 7, 5, ∑d2=3.5\sum d^2=3.5 and rs=1−21336=0.9375r_s=1-\frac{21}{336}=0.9375. You may instead enter the ranks into a calculator.

Key termstied ranksmean rank
Exam tip

After sharing ranks, check that the ranks still add up to n(n+1)2\frac{n(n+1)}{2}.

Section 5

Choosing and interpreting the coefficient

Use the PMCC when the data are measured and the scatter diagram is roughly elliptical (linear association). Use Spearman's coefficient when the data are ranks, or when the relationship is monotonic but not linear, or when outliers are present. If rsr_s is much larger than rr, the relationship may be curved or contain an extreme value. Always interpret in context: for example, rs=0.94r_s=0.94 means students who score highly in mathematics tend to score highly in physics. Do not claim cause.

Key termslinear associationoutlier
Common mistake

Using the PMCC for data that are only ranks.

That's the notes covered.

Carry on to the next subtopic.

Exam questions on Product moment and Spearman's rank correlation

  1. A researcher records the hours of sleep, xx, and the reaction time, yy ms, of each of 8 randomly chosen students. The summary statistics are Sxx=62.5S_{xx}=62.5, Syy=40S_{yy}=40 and Sxy=−45S_{xy}=-45.
    Interpret the value of rr between xx and yy in context, and state an assumption about the population needed to use rr in a hypothesis test.2 marks
  2. Two judges each rank six paintings, AA to FF, from 1 (best) to 6 (worst). Judge 1 ranks AA to FF as 3,1,2,5,4,63, 1, 2, 5, 4, 6 respectively. Judge 2 ranks them as 2,1,4,5,3,62, 1, 4, 5, 3, 6 respectively.
    State, with a reason, whether Spearman's rank correlation coefficient or the product moment correlation coefficient is more appropriate for these data.2 marks
  3. Seven students sit a mathematics test and a physics test. Their scores, in the order of students 11 to 77, are: mathematics 56,61,61,70,48,75,6656, 61, 61, 70, 48, 75, 66 and physics 50,58,49,64,44,70,6050, 58, 49, 64, 44, 70, 60.
    Rank the mathematics scores and the physics scores from lowest (rank 1) to highest, and hence show that ∑d2=3.5\sum d^2=3.5.3 marks
See the full worksheet

Written by the Exaim team, led by Shaun Daswani (Head of Upper Secondary, Improve ME Institute; MSc Financial Mathematics, Imperial College London; BSc, UCL) and Jason Daswani (operational lead, Improve ME Institute; LSE).