Scatter plots and correlation
What this lesson covers
- Describe trend, association, strength and unusual points.
- r measures straight-line strength from −1 to 1.
- Association does not prove cause.
What to describe
- Trend: linear or curved.
- Association: positive or negative.
- Strength: how close the points are to the trend.
- Unusual features: outliers and groups.
Reading r
- r only measures straight-line relationships.
| r | Meaning |
|---|---|
| 0.95 | Strong positive |
| 0.5 | Moderate positive |
| 0 | No linear relationship |
| −0.8 | Strong negative |
What strength looks like
- The closer the points sit to a straight line, the stronger the relationship.
Try it: drag the points
- Drag a point and watch the line and r change. Then press Add an outlier and see how much one point can do.
Statistics explorer
A full description
- For height and shoe size in an invented class of 30, r = 0.85.
- Trend: linear
- Association: positive, taller students have larger feet
- Strength: strong, r = 0.85
- Unusual: note any outliers or groups
Outliers matter
- One point far from the others can raise or lower r a lot.
- Find out why it is there before deciding what to do. Never delete a point simply because it is awkward.
Try it: line and residuals
Common mistakes
- Saying r = 0 means no relationship.It may be curved, so look at the graph.
- Saying a strong r proves cause.A third variable may explain both.
Try it: read r, then beat the traps
Your turn
What does r = −0.9 suggest?
What does r = 0.1 suggest?
Which r shows the strongest relationship?
Two variables have r = 0.9. What can you say?
A student writes r = 1.3 for a strong positive relationship. What is wrong?
In what order should you describe a scatter plot?
One student's point sits far from the rest and lowers r a lot. What should you do first?
A scatter plot shows a clear U-shaped curve, and r = 0.02. Which is true?
Show answer
1. A strong negative linear relationship 2. Almost no linear relationship 3. −0.95, as its size is closest to 1 4. They are linked, but cause is not shown 5. r can never be bigger than 1: it always lies from −1 to 1, and a strong positive r is close to 1. 6. Trend, association, strength, then unusual features: linear or curved, positive or negative, how close to the trend, then outliers and groups. 7. Find out why it is there before deciding: never delete a point simply because it is awkward. 8. There is a curved relationship, not a linear one: r = 0.02 only says there is almost no straight-line relationship.
Sample question: Achieved
For 8 used cars of the same model, age (years) and price (thousands of dollars) are: (2, 24), (3, 22), (4, 21), (5, 17), (6, 16), (8, 13), (9, 10), (10, 9). The correlation coefficient is r = −0.99. Describe the relationship in context.
Hint
Describe four things in order: trend, association, strength, and anything unusual. Use the variables' names.
Answer
The relationship is linear, negative and very strong (r = −0.99), with no unusual points: older cars of this model tend to sell for less, about $24,000 at 2 years old falling to about $9,000 at 10 years.
Step by step
- A full description covers trend, association, strength and unusual features, in that order.
- Trend: the prices fall by similar amounts as age rises, so the pattern is close to a straight line. It is linear.
- Association: as age goes up, price goes down. That is a negative association.
- Strength: r = −0.99 is very close to −1, so the points sit very close to a straight line. It is very strong.
- Classic mistake: calling r = −0.99 weak because it is negative. The sign gives the direction; the size gives the strength.
- Unusual features: every point follows the pattern, so there are no outliers and no separate groups.
- Context: older cars of this model tend to be cheaper, from about $24,000 at 2 years down to about $9,000 at 10 years.
- Check: the cheapest car (9 thousand) is the oldest (10 years), which fits a negative relationship.
Full working
- points close to a straight linetrend: linear
- price falls as age risesassociation: negative
- r = −0.99, close to −1strength: very strong
- no outliers or groupsunusual features: none
- Linear, negative, very strong: older cars tend to cost less
Sample questions: Merit
Eight kayakers record weeks of training (x) and how many seconds they cut from their race time (y): (1, 3), (2, 5), (3, 4), (4, 7), (5, 8), (6, 8), (7, 10), (8, 11). Here r = 0.97. A ninth kayaker trained for 9 weeks but cut only 2 seconds, because of a shoulder injury. With this point added, r = 0.39. What does this tell you, and what should the analyst do?
Hint
Think about where the new point sits compared with the pattern, and whether its cause belongs to the group being studied.
Answer
One point dropped r from 0.97 to 0.39, so it is a very influential outlier: it sits far below the trend at the largest x. Investigate it. The injury is a known cause outside normal training, so it is reasonable to analyse without it and report that it was left out and why, giving both values of r.
Step by step
- Without the new point, r = 0.97: a very strong positive linear relationship. More training goes with a bigger time cut.
- The ninth point is at x = 9, the most training, but y = 2, one of the smallest cuts. The trend suggests about 12 seconds there.
- Points at the end of the x range pull hardest on the line and on r. So this one point drags r down to 0.39.
- So the outlier is very influential: one kayaker changes the story from very strong to weak.
- Classic mistake: deleting the point just because it spoils the result. You need a reason.
- Here there is a reason: an injury. The study is about how training affects time, and an injury is a different cause.
- So it is fair to fit the model without this kayaker, but say so in the report and explain why.
- Report both values: r = 0.97 without the injured kayaker and 0.39 with him, so a reader can judge.
- If there were no known reason, keep the point and comment on the difference it makes.
Full working
- 8 points: r = 0.97very strong positive
- (9, 2) far below the trend at the largest xinfluential outlier
- r falls to 0.39 with it
- injury is a known cause outside the studyreason to exclude
- Influential outlier: investigate, analyse without it with the reason stated, report both r values
For the 8 used cars (age in years, price in thousands of dollars), r = −0.99. A student changes age into months and price into dollars, and also swaps the axes so price is on the x axis. She expects r to change. Will it? Explain why, and say what does change when the axes are swapped.
Hint
r measures how close the points are to a straight line. Ask whether stretching an axis or swapping them changes that.
Answer
r stays at −0.99 every time. Changing units multiplies every value by the same positive number, which stretches the graph but keeps the points just as close to a line, and r is symmetric in x and y. What changes on swapping is the meaning: price becomes the explanatory variable, and a fitted line would change, since age is the natural explanatory variable here.
Step by step
- r describes how tightly the points cluster around a straight line, and in which direction.
- Changing years to months multiplies every age by 12. Changing thousands of dollars to dollars multiplies every price by 1000.
- That only stretches the graph. The points keep the same shape and the same closeness to a line, so r stays −0.99.
- Classic mistake: thinking bigger numbers mean a bigger r. r has no units, so it does not depend on the units of the data.
- Swapping the axes: r is worked out from the products of x and y deviations, which are the same either way round. So r is again −0.99.
- Calculation check: with the new units and with the axes swapped, a calculator still gives r = −0.99.
- What does change when swapping is the roles. The x variable should be the explanatory one, the one we think helps explain the other.
- Age explains price, not the other way round, so age belongs on the x axis.
- If the student fitted a line with price on x, she would get a different line, which is the wrong one for predicting price from age.
Full working
- months = 12 × years, dollars = 1000 × thousandspositive multiples
- stretching does not change closeness to a liner = −0.99
- r is the same for (x, y) and (y, x)swap: r = −0.99
- swap changes the explanatory variableage should be on x
- r stays −0.99; only the roles of the variables change
Sample questions: Excellence
A made-up sample of 8 houses gives age (years) and price (thousands of dollars). Four are in Gore: (10, 420), (20, 390), (30, 370), (40, 330). Four are in Auckland: (50, 1250), (60, 1180), (70, 1140), (80, 1060). For all 8 together, r = 0.80, and a student concludes that older houses are worth more. Within each town r = −0.99. Evaluate the student's conclusion.
Hint
Look at the two groups separately. Ask what else changes between the groups as well as age.
Answer
The conclusion is wrong. Within each town older houses are worth less (r = −0.99, falling about $2,900 a year in Gore and $6,100 a year in Auckland). The overall r = 0.80 is created by the groups: the Auckland houses are both older and in a far dearer market. Location is a lurking variable, so the data should be analysed by town.
Step by step
- Start by graphing in your head: the Gore points sit at ages 10 to 40 and prices about 330 to 420. The Auckland points sit at ages 50 to 80 and prices about 1060 to 1250.
- Within Gore, as age goes up, price goes down: 420, 390, 370, 330. Within Auckland the same: 1250, 1180, 1140, 1060.
- So in each town the relationship is strong and negative, r = −0.99. In Gore the slope is about −2.9 thousand a year; in Auckland about −6.1 thousand a year.
- Put together, the Auckland cluster is up and to the right of the Gore cluster. A line through both clusters slopes upwards, giving r = 0.80.
- So the positive r comes from the difference between the towns, not from age.
- Location is a lurking variable: Auckland houses in this sample are older and also in a much more expensive market.
- Classic mistake: describing the overall scatter without noticing the two groups. Always look for clusters before quoting r.
- A fair conclusion: in each town, older houses tend to sell for less. The data give no support to older houses being worth more.
- Limitation: only four houses per town, and made-up data, so the slopes are rough. A real study would need many more houses and other variables, such as size.
- Better method: analyse each town separately, or include location in the model.
Full working
- Gore r = −0.99, slope −2.9negative within the group
- Auckland r = −0.99, slope −6.1negative within the group
- all 8: r = 0.80positive only because of the two clusters
- location lurks: older and dearergroups explain the overall r
- analyse by town; small made-up samplelimitations
- Conclusion is wrong: within each town older houses are worth less; location creates the positive r
For 7 students, hours of sleep and test score are: (5, 50), (6, 62), (7, 70), (8, 72), (9, 70), (10, 62), (11, 50). Show that r = 0 for this data. A student says this proves sleep has no effect on score. Evaluate this claim.
Hint
r is 0 exactly when the sum of (x − mean x)(y − mean y) is 0. The x values are symmetric about 8 and the scores are symmetric too.
Answer
The mean sleep is 8, and each pair of x values the same distance either side of 8 has the same score, so the products (x − 8)(y − ȳ) cancel in pairs and their sum is 0, giving r = 0. But the claim is wrong: score rises from 50 to 72 and falls back to 50. r only measures straight-line relationships, and this one is curved, so a curved model fits.
Step by step
- r = 0 exactly when the sum of (x − x̄)(y − ȳ) is 0, because that sum is the top of the formula for r.
- Mean of x: (5 + 6 + 7 + 8 + 9 + 10 + 11) ÷ 7 = 56 ÷ 7 = 8.
- Pair the students either side of 8: 5 and 11, 6 and 10, 7 and 9. In each pair the scores are equal: 50 and 50, 62 and 62, 70 and 70.
- Take 5 and 11: (5 − 8)(50 − ȳ) + (11 − 8)(50 − ȳ) = −3(50 − ȳ) + 3(50 − ȳ) = 0. The same happens for the other two pairs.
- The middle student has x − 8 = 0, so that product is 0 too. So the whole sum is 0 and r = 0.
- Notice we never needed ȳ (it is 436 ÷ 7 ≈ 62.3). The symmetry does all the work.
- Now the claim. r = 0 means no straight-line relationship, not no relationship.
- The scores rise from 50 at 5 hours to 72 at 8 hours, then fall back to 50 at 11 hours. That is a clear curved pattern.
- Classic mistake: reading r without graphing. Always look at the scatter plot first.
- So sleep does seem linked to score, with about 8 hours best in this data. A curved model, such as a quadratic, would describe it.
- Limitations: 7 students is a small sample, and the data cannot prove cause, but they certainly do not show no effect.
Full working
- x̄ = 56 ÷ 7 = 8
- x = 8 − d and 8 + d have equal ysymmetric pairs
- (−d)(y − ȳ) + (d)(y − ȳ) = 0 for each pairproducts cancel
- sum of (x − x̄)(y − ȳ) = 0, so r = 0
- scores rise then fallcurved, not no relationship
- r = 0, but sleep and score are clearly related by a curve; the claim is wrong
What to take away
- Graph first, r second.
- Correlation is not cause.
Challenge
For 12 Canterbury farms, r = 0.72 between annual rainfall x (mm) and hay yield y (tonnes per hectare). Give the new value of r, or say it cannot be found, after each change on its own: (a) rainfall is written in cm; (b) yield is replaced by the shortfall below a 10 tonne target, 10 − y; (c) rainfall is replaced by how far each farm is above the regional mean of 650 mm, x − 650; (d) both (a) and (b) are done together; (e) yield is replaced by y². Explain each answer.
Hint
r measures how close the points are to a straight line and which way the line slopes. For each change, ask whether straight lines stay straight, and whether the direction of the axis is reversed.
Answer
(a) 0.72; (b) −0.72; (c) 0.72; (d) −0.72; (e) cannot be found from r alone, because squaring is not a straight-line change.
Step by step
- (a) Dividing every x by 10 squashes the graph sideways but keeps the points exactly as close to a line, so r stays 0.72.
- (b) 10 − y flips the y axis upside down: farms with more yield now have smaller values. The closeness is the same but the direction reverses, so r = −0.72.
- (c) Subtracting 650 slides every point left by the same amount. Nothing about the pattern changes, so r = 0.72.
- (d) The unit change keeps r and the flip changes its sign, so r = −0.72.
- (e) Squaring stretches large yields more than small ones, so a straight pattern may bend. The new r depends on the actual data, so it cannot be found from 0.72.
Full working
- x ÷ 10: stretch onlyr = 0.72
- 10 − y: every (y − ȳ) changes sign, so Σ(x − x̄)(y − ȳ) changes signr = −0.72
- x − 650: every (x − x̄) unchangedr = 0.72
- (a) and (b): stretch and flipr = −0.72
- y²: not a straight-line changer unknown
- 0.72, −0.72, 0.72, −0.72, cannot be found
A market stall records its profit y (thousands of dollars) in its first five months x: (1, 3), (2, 5), (3, 7), (4, k), (5, 11). Four of the points lie exactly on a straight line. (a) Find the integer k that makes r exactly 0. (b) For which values of k is r positive? (c) What is r when k = 9? (d) Explain what part (a) shows about using r alone to describe a relationship.
Hint
r has the same sign as Σ(x − x̄)(y − ȳ), the top of the slope formula, and is 0 exactly when it is 0. Since Σ(x − x̄) = 0, that sum equals Σ(x − x̄)y.
Answer
(a) k = −11, a loss of $11,000. (b) k > −11. (c) r = 1. (d) One unusual point can wipe out a perfect pattern in the other four, so r = 0 does not mean no relationship; always look at the graph and describe unusual points.
Step by step
- x̄ = 3, so the x deviations are −2, −1, 0, 1, 2.
- Σ(x − x̄)y = −2 × 3 − 1 × 5 + 0 × 7 + 1 × k + 2 × 11 = k + 11.
- r = 0 exactly when this is 0, so k = −11. Then r is positive when k + 11 > 0, that is k > −11.
- When k = 9, the point (4, 9) lies on the line through the others, y = 1 + 2x, so all five points are on one rising line and r = 1.
- So the same four points can give r anywhere from 0 to 1 depending on a single month. r = 0 here hides a perfectly straight rise in four of the five months.
Full working
- x̄ = 3; x − x̄: −2, −1, 0, 1, 2deviations
- Σ(x − x̄)(y − ȳ) = Σ(x − x̄)ybecause Σ(x − x̄) = 0
- −6 − 5 + 0 + k + 22 = k + 11substitute
- k + 11 = 0, k = −11r = 0
- k + 11 > 0, k > −11r positive
- k = 9: all points on y = 1 + 2xr = 1
- (a) k = −11; (b) k > −11; (c) r = 1; (d) one point can hide a strong pattern
In a pilot year a small training course admitted all 10 applicants. Entry test score x and final course grade y: (40, 45), (45, 50), (50, 48), (55, 56), (60, 58), (70, 66), (75, 70), (80, 62), (85, 70), (90, 66). From next year only applicants scoring 70 or more will be admitted. The director looks at the five students who scored 70 or more and says: "Among good applicants the test tells us nothing about grades, so we can drop the test." (a) Show that r = 0 for those five students. (b) For all ten students r = 0.91. Explain why the two values differ so much. (c) Evaluate the director's conclusion.
Hint
(a) Use Σ(x − x̄)(y − ȳ) = Σ(x − x̄)y for the five. (b) Think about what happens to r when only a narrow slice of the x values is kept. (c) Ask what the test is used for: comparing all applicants, or only those already above 70?
Answer
(a) For the five, x̄ = 80 and Σ(x − 80)y = 0, so r = 0. (b) Keeping only scores 70 to 90 cuts the range, so the steady rise across 40 to 90 is lost and only scatter remains. (c) Wrong: the test is used to choose among all applicants, and across the full range it has a very strong link with grades (r = 0.91). Dropping it would admit weaker applicants. r = 0 in the top group only says the test does not separate students who all already passed it.
Step by step
- For the five top scorers, x̄ = 80 and the deviations are −10, −5, 0, 5, 10.
- Σ(x − 80)y = −10 × 66 − 5 × 70 + 0 × 62 + 5 × 70 + 10 × 66 = 0, so the top of r is 0 and r = 0.
- Across all ten, grades rise from about 45 to about 66 as scores go from 40 to 90, a strong linear pattern, r = 0.91.
- Cutting the x range to a narrow slice removes most of that rise, leaving mostly the ups and downs between similar students. This is called restriction of range: r is smaller in a narrower slice.
- The director's claim uses the wrong group. The test is applied to all applicants, and over all of them it predicts grades well. Without it, low scorers like the 40 to 60 group would be admitted.
- A fair conclusion: the test separates weak from strong applicants well, but does not rank students who are already above 70.
Full working
- top five: x̄ = 400 ÷ 5 = 80mean score
- Σ(x − 80)y = −660 − 350 + 0 + 350 + 660 = 0pairs cancel
- r = 0 for the top fivetop of r is 0
- all ten: r = 0.91given
- x range 70 to 90 instead of 40 to 90restriction of range
- (a) r = 0; (b) narrow range hides the trend; (c) the conclusion is wrong, the test is a strong predictor across all applicants



