Correlation

Rising together, falling apart, or neither.

Positive correlation

A scatter plot shows two measurements of each person or thing as one dot. Correlation describes the pattern the dots make: whether the two measurements tend to rise together, move in opposite directions, or neither.

When the dots rise together, up and to the right, the correlation is positive: as one measurement increases, the other tends to increase too. People who practice for more hours tend to get higher scores.

hours practicedscore

The dots rise together, up and to the right. That is positive correlation.

Negative correlation

When one measurement climbs while the other falls, the dots run down from the upper left to the lower right, and the correlation is negative: as one measurement increases, the other tends to decrease. In this group, people who watched more hours of TV tended to get lower scores.

hours of TVscore

As the hours of TV go up, the scores go down. That is negative correlation.

No correlation

When the dots form a shapeless cloud, with no drift up or down, there is no correlation. Knowing one measurement tells you nothing about the other: a small shoe size goes with high and low scores alike, and so does a large one.

One way to check is to split the dots into a left half and a right half and compare the average height of each half. If the right half is about as high as the left half, the cloud has no drift.

shoe sizescore

A shapeless cloud is no correlation: one measurement tells you nothing about the other.

Strong and weak

Correlation also has a strength. The correlation is strong when the dots lie close to a straight line, and weak when they drift in one direction but are widely scattered about it. When every dot lies exactly on a straight line, the correlation is perfect.

A full description gives the strength and the direction together: “strong positive correlation”, “weak negative correlation”. With a weak correlation, the drift is still there, but one measurement is a poor guide to the other.

Strong positive correlation: the dots rise and lie close to a straight line.

Weak positive correlation: the dots still drift upward, but they are widely scattered.

Strength is not steepness

Strength measures how closely the dots follow a line, not how steep the line is. Dots lying exactly on a nearly flat line have a perfect positive correlation, even though y hardly changes as x increases. Dots scattered about a steep line have a weaker correlation than that.

Every dot lies exactly on the line y = 0.2x + 4. The line is nearly flat, and the correlation is perfect.

Correlation measures a straight-line pattern only

Correlation describes how well the dots fit a straight line. Two measurements can be closely related in a curve and still show little or no correlation.

A ball is thrown straight up. Every half second its height is measured: 8.75 m after 0.5 seconds, then 15 m, 18.75 m, 20 m at 2 seconds, and then 18.75 m, 15 m and 8.75 m as it falls. The height depends completely on the time, yet the dots rise and then fall by the same amounts, so they have no upward or downward drift. There is no correlation between time and height, because correlation looks only for a straight line.

So look at the scatter plot before describing it. “No correlation” means no straight-line pattern; it does not always mean no relationship.

time (s)height (m)

The ball’s heights lie on a smooth arch. The relationship is exact, but it is not a straight line, and there is no correlation.

Describing a correlation in context

Say the strength, the direction, and what they mean for the two quantities: “There is a strong positive correlation between hours practiced and score: students who practiced for longer tended to score higher.” The words “tended to” matter. A correlation describes the group, and some individuals will not follow it.

A correlation also does not show that one measurement causes the other. That is the subject of a later lesson, Correlation Is Not Causation.

The strength and the direction can also be measured by one number, the correlation coefficient, which runs from −1 for a perfect negative correlation, through 0 for no correlation, to +1 for a perfect positive correlation.

The mean point and a line of best fit

The two applications below use a line of best fit, which is the subject of the next lesson. A line of best fit is one straight line drawn through the middle of the dots, following their drift, with about as many dots above it as below it. It passes through the mean point, whose coordinates are the mean of the x-values and the mean of the y-values.

A line of best fit only makes sense when there is a correlation for it to follow. When there is none, the best estimate of y is simply the mean of the y-values, whatever x is.

The gradient of the line is a rate: the change in y for each increase of 1 in x, in the units of y per unit of x. With a negative correlation the line falls, so its gradient is negative. The intercept is the value of y that the line gives at x = 0.

Worked example: Umbrellas Against Birthday Cards, and a Prediction from Ten Days of Sales

Question A shop recorded, on ten days, the umbrellas and the birthday cards it sold. The pairs of (umbrellas, cards) were (2, 28), (4, 20), (5, 26), (7, 22), (8, 24), (11, 27), (13, 21), (14, 25), (16, 18) and (20, 29). (a) Find the mean point, and describe the correlation between the two sales. (b) The manager wants to predict the card sales on a day when 30 umbrellas are sold. Say what should be done, and give the best estimate the data supports.

  1. 1.Find the mean point. The umbrellas total 2 + 4 + 5 + 7 + 8 + 11 + 13 + 14 + 16 + 20 = 100, so the mean is 100 ÷ 10 = 10 umbrellas.

    0816243205101520birthday cardsumbrellas sold10 days: umbrellas against cards
    0816243205101520birthday cardsumbrellas sold10 days: umbrellas against cards
    The ten days, with the umbrellas across and the birthday cards up. The points fill the diagram in no particular direction.
  2. 2.The cards total 28 + 20 + 26 + 22 + 24 + 27 + 21 + 25 + 18 + 29 = 240, so the mean is 240 ÷ 10 = 24 cards, and the mean point is (10, 24).

    0816243205101520birthday cardsumbrellas sold100 divided by 10 = 10 umbrellas240 divided by 10 = 24 cards
    0816243205101520birthday cardsumbrellas sold100 divided by 10 = 10 umbrellas240 divided by 10 = 24 cards
    The cross is the mean point, (10, 24).
  3. 3.Split the days at the middle. On the five days with the fewest umbrellas the cards were 28, 20, 26, 22 and 24, which total 120 and average 24. On the five days with the most umbrellas they were 27, 21, 25, 18 and 29, which also total 120 and average 24.

    0816243205101520birthday cardsumbrellas sold5 quietest days: 120 cards, mean 245 busiest days: 120 cards, mean 24
    0816243205101520birthday cardsumbrellas sold5 quietest days: 120 cards, mean 245 busiest days: 120 cards, mean 24
    The dashed line splits the days into the five with the fewest umbrellas and the five with the most. Each half has a mean of 24 cards, drawn as a bar at that height.
  4. 4.(a) The two halves have the same mean, and the points are scattered over the whole diagram with no drift upward or downward, so there is no correlation between umbrella sales and card sales.

    0816243205101520birthday cardsumbrellas soldthe two halves sit at the same heightno correlation, so no line of best fit
    0816243205101520birthday cardsumbrellas soldthe two halves sit at the same heightno correlation, so no line of best fit
    (a) The two bars are level, so there is no correlation and no line of best fit should be drawn.
  5. 5.(b) No line of best fit should be drawn. A line needs a trend to follow and there is none here, so any line drawn by eye would only be repeating the accidents of these ten days. The best estimate for the cards is the mean, 24 cards, whatever the umbrellas do. Check: 30 umbrellas is also more than any day recorded, so even a real trend could not have been followed that far.

    0816243205101520birthday cardsumbrellas soldthe best estimate is the mean, 24 cards30 umbrellas is off the diagram
    0816243205101520birthday cardsumbrellas soldthe best estimate is the mean, 24 cards30 umbrellas is off the diagram
    (b) The one honest estimate is the mean, drawn right across at 24 cards. It does not change with the umbrellas.

Answer: (a) the mean point is (10, 24) and there is no correlation: the five days with the fewest umbrellas and the five with the most both averaged 24 cards; (b) no line of best fit should be drawn, so the best estimate is the mean, 24 cards

Common mistakes

  • Drawing a line through the leftmost and the rightmost points, (2, 28) and (20, 29), and calling it the line of best fit. Two points always determine a line, so this can be done to any scatter diagram at all, and it says nothing about the other eight days.
  • Reading the high value at 20 umbrellas as the start of an upward trend. One point cannot show a trend, and the day beside it, at 16 umbrellas, has the lowest card sales of all ten.

More scatter plots and correlation problems, worked step by step →

Worked example: A Car's Age Against Its Price, Where the Gradient Is the Value Lost Each Year

Question A dealer recorded the age and the price of eight cars of one model. The pairs of (age in years, price in thousands of dollars) were (1, 17), (2, 14), (3, 14), (4, 14.5), (4, 9), (5, 11.5), (6, 8.5) and (7, 7.5). The line of best fit passes through (2, 15) and (6, 9). (a) Find the gradient of the line and say what it means for these cars. (b) Find the equation of the line and say what its intercept means.

  1. 1.Plot the eight cars with the age along the horizontal axis and the price up the vertical axis. The points fall from left to right, so age and price are in negative correlation: the older a car is, the less it costs.

    0510152002468price, $ thousandage, years8 cars: age against pricethe points fall to the right
    0510152002468price, $ thousandage, years8 cars: age against pricethe points fall to the right
    The eight cars, with the age across and the price up. The points fall from left to right, which is negative correlation.
  2. 2.Use the two points the line passes through. From (2, 15) to (6, 9) the age rises by 6 − 2 = 4 years and the price falls by 15 − 9 = 6 thousand dollars.

    0510152002468price, $ thousandage, years4 years6from (2, 15) to (6, 9)across 4 years, down 6 thousand
    0510152002468price, $ thousandage, years4 years6from (2, 15) to (6, 9)across 4 years, down 6 thousand
    The gradient triangle under the line: from (2, 15) to (6, 9) the age rises by 4 years while the price falls by 6 thousand dollars.
  3. 3.(a) The gradient is 9 − 156 − 2 = −64 = −1.5, and its units are thousands of dollars for each year. A car of this model loses about $1500 of its value every year.

    0510152002468price, $ thousandage, years4 years6gradient = 6 over 4 = 1.5, going downabout $1500 lost every year
    0510152002468price, $ thousandage, years4 years6gradient = 6 over 4 = 1.5, going downabout $1500 lost every year
    (a) The gradient is 9 − 156 − 2 = −1.5 thousand dollars a year, so a car loses about $1500 of its value each year.
  4. 4.Find the intercept. Going back from (2, 15) by 2 years adds 2 × 1.5 = 3 thousand dollars, so at age 0 the line gives 15 + 3 = 18 thousand dollars.

    0510152002468price, $ thousandage, years4 years6back 2 years adds 3 thousandat age 0 the line gives 18 thousand
    0510152002468price, $ thousandage, years4 years6back 2 years adds 3 thousandat age 0 the line gives 18 thousand
    Carried back to the price axis, the line reaches 18 thousand dollars at age 0: the circle on the axis.
  5. 5.(b) The line of best fit is p = 18 − 1.5a, where a is the age in years and p is the price in thousands of dollars. The intercept 18 is the price at age 0, so a car of this model cost about $18 000 when it was new. Check: the mean age is 32 ÷ 8 = 4 years and the mean price is 96 ÷ 8 = 12 thousand dollars, and 18 − 1.5 × 4 = 12, so the line does pass through the mean point (4, 12).

    0510152002468price, $ thousandage, years4 years6p = 18 - 1.5a: about $18 thousand newthe mean point (4, 12) is on the line
    0510152002468price, $ thousandage, years4 years6p = 18 - 1.5a: about $18 thousand newthe mean point (4, 12) is on the line
    (b) The line is p = 18 − 1.5a, the intercept 18 is about $18 000 when new, and the cross shows the mean point (4, 12) sitting on the line.

Answer: (a) the gradient is −1.5 thousand dollars a year, so a car of this model loses about $1500 of its value each year; (b) p = 18 − 1.5a, which passes through the mean point (4, 12), and the intercept 18 means the car cost about $18 000 when new

Common mistakes

  • Giving the gradient as 1.5 because the fall of 6 thousand dollars is a positive amount of money. The price goes down as the age goes up, so the gradient is negative, and that sign is what records the negative correlation.
  • Calling the intercept the price of a car in the table that is 0 years old. No car in the table is new; 18 thousand dollars is what the line predicts at age 0, and it is worth quoting only because 0 is close to the youngest car recorded, which is 1 year old.

More scatter plots and correlation problems, worked step by step →

Practice Correlation in the app