Scatterplot vs residual plot

By Jude Wallis · Published

A scatterplot graphs the data: each point is an (x, y) pair, and it shows the direction, form, and strength of the relationship. A residual plot graphs the leftovers after fitting a line: each point is a residual, observed y minus predicted y, and it shows whether a line was the right model.

AP Statistics: Unit 5 (topics 5.1 Graphical Representations Between Two Quantitative Variables, 5.4 Residuals). Scatterplots are topic 5.1 and residual plots are topic 5.4 in Unit 5, Regression Analysis, of the Fall 2026 AP Statistics course. Curvature in a residual plot is evidence that a linear model is not appropriate. The course has no topic on transforming data to achieve linearity.

Scatterplot vs residual plot: the short answer

The two plots share a horizontal axis and differ on the vertical one. A scatterplot puts the response variable yy on the vertical axis, so you see the raw relationship between two quantitative variables. A residual plot puts the residual, y−y^y - \hat{y} ("y minus y-hat", observed minus predicted), on the vertical axis, so you see only what the regression line failed to capture.

They are drawn at different stages. The scatterplot comes first, before any model, and tells you whether fitting a line is reasonable. The residual plot comes after the line is fitted and checks that decision. A scatterplot can exist with no regression line. A residual plot cannot, because residuals are measured from a line.

What a scatterplot shows

A scatterplot has one point for each individual, placed at its xx value (explanatory variable) and its yy value (response variable). You describe what you see with four features:

  • Direction: positive if yy tends to rise as xx rises, negative if it tends to fall.
  • Form: linear if the points follow a straight path, nonlinear if they curve.
  • Strength: how closely the points follow that form.
  • Unusual features: points far from the pattern, or separate clusters.

The scatterplot is where you learn what the relationship looks like in the units of the data. It is also where you decide whether a straight line is worth fitting at all.

What a residual plot shows

A residual plot is built from a fitted line y^=a+bx\hat{y} = a + bx. For each point, compute the residual y−y^y - \hat{y} and plot it against xx, or against the predicted value y^\hat{y}. A horizontal line at 0 marks where the regression line sits. Points above 0 are observations the line underpredicted, and points below 0 are ones it overpredicted.

You read a residual plot for pattern:

  • No pattern, with points scattered randomly above and below 0, supports using a linear model.
  • A curve, such as residuals that are positive, then negative, then positive again, says a line is not the appropriate model.

For a least-squares line the residuals always add to 0 and never show an upward or downward linear trend, because the line has already taken out the linear part of the relationship. Anything left that is not random is what the line missed. More on reading these is in how to interpret residual plots.

The differences side by side

FeatureScatterplotResidual plot
Vertical axisResponse variable yyResidual y−y^y - \hat{y}
Horizontal axisExplanatory variable xxxx, or the predicted value y^\hat{y}
Needs a fitted line firstNoYes
Reference lineNone requiredHorizontal line at 0
Main questionWhat is the relationship between the variables?Is a line an appropriate model for it?
What you look forDirection, form, strength, unusual featuresRandom scatter, or a leftover pattern
Shows the direction of the relationshipYesNo

The last row matters. A residual plot from a least-squares line has no overall upward or downward tilt, whether the original relationship was positive or negative, so it cannot tell you the direction or the strength of the association.

When to use which

Use both, in order.

  1. Draw the scatterplot. Describe direction, form, and strength, and note any unusual points.
  2. If the form looks roughly linear, fit the least-squares line.
  3. Draw the residual plot. If it shows random scatter, the linear model is appropriate. If it shows a curve, it is not.

The residual plot is useful because it magnifies. On a scatterplot with a steep trend, a gentle bend is easy to miss, since the eye follows the overall rise. Subtracting the line removes that rise and stretches the leftover variation to fill the whole vertical axis, so the bend becomes obvious.

You can make both plots from your own data with the regression calculator.

The classic mix-up and how to avoid it

The first mistake is reading a residual plot as if it were a scatterplot. A residual plot with no pattern is the good outcome: the line described the relationship well and left only random scatter. It says nothing about whether the variables are related, which is the scatterplot's job.

The second mistake is using a high correlation as proof that a line fits. Data that follow a curve can have a correlation close to 1. The worked example below has r≈0.98r \approx 0.98 and a residual plot with a clear U shape. Correlation measures how strong a linear association is. The residual plot is the check on whether the form is linear.

The third mistake is getting the subtraction backward. A residual is observed minus predicted, so a point above the line has a positive residual.

A high correlation with a curved residual plot

Five data points are (1, 2), (2, 5), (3, 10), (4, 17), (5, 26). The least-squares line is y^=−6+6x\hat{y} = -6 + 6x and the correlation is r≈0.981r \approx 0.981. Compute the residuals, describe the residual plot, and decide whether a linear model is appropriate.

  1. Verify the line passes through the point of means. xˉ=1+2+3+4+55=3\bar{x} = \frac{1+2+3+4+5}{5} = 3 and yˉ=2+5+10+17+265=12\bar{y} = \frac{2+5+10+17+26}{5} = 12, and −6+6(3)=12-6 + 6(3) = 12.

  2. Compute the predicted values from y^=−6+6x\hat{y} = -6 + 6x: for x=1,2,3,4,5x = 1, 2, 3, 4, 5 they are 0, 6, 12, 18, 24.

  3. Compute each residual as observed minus predicted: 2−0=22 - 0 = 2, 5−6=−15 - 6 = -1, 10−12=−210 - 12 = -2, 17−18=−117 - 18 = -1, 26−24=226 - 24 = 2.

  4. Check that the residuals sum to zero: 2−1−2−1+2=02 - 1 - 2 - 1 + 2 = 0.

  5. Plot the residuals against xx: the points are (1, 2), (2, -1), (3, -2), (4, -1), (5, 2). They start above 0, dip below 0 in the middle, and return above 0 at the end, a U shape.

  6. Interpret. The scatterplot shows a strong positive association, and r≈0.981r \approx 0.981 agrees. The curved residual plot shows that the form is not linear: the line overpredicts in the middle and underpredicts at both ends.

The residuals are 2, -1, -2, -1, 2. The residual plot is U-shaped, so a linear model is not appropriate even though r≈0.981r \approx 0.981. The scatterplot shows a strong positive relationship, and the residual plot shows that the relationship is curved. These points lie exactly on y=x2+1y = x^2 + 1.

Building a residual plot from a scatterplot

Five data points are (2, 7), (4, 10), (6, 16), (8, 17), (10, 25). The least-squares line is y^=2.1+2.15x\hat{y} = 2.1 + 2.15x. Find the coordinates of the points on the residual plot and decide whether a linear model is appropriate.

  1. Compute the predicted values: 2.1+2.15(2)=6.42.1 + 2.15(2) = 6.4, 2.1+2.15(4)=10.72.1 + 2.15(4) = 10.7, 2.1+2.15(6)=15.02.1 + 2.15(6) = 15.0, 2.1+2.15(8)=19.32.1 + 2.15(8) = 19.3, 2.1+2.15(10)=23.62.1 + 2.15(10) = 23.6.

  2. Compute the residuals, observed minus predicted: 7−6.4=0.67 - 6.4 = 0.6, 10−10.7=−0.710 - 10.7 = -0.7, 16−15.0=1.016 - 15.0 = 1.0, 17−19.3=−2.317 - 19.3 = -2.3, 25−23.6=1.425 - 23.6 = 1.4.

  3. Check the sum: 0.6−0.7+1.0−2.3+1.4=00.6 - 0.7 + 1.0 - 2.3 + 1.4 = 0.

  4. List the residual plot points, keeping the same xx values: (2, 0.6), (4, -0.7), (6, 1.0), (8, -2.3), (10, 1.4).

  5. Look for a pattern. The signs alternate: positive, negative, positive, negative, positive. The points do not follow a curve.

  6. Conclude that the residuals show no clear pattern, which supports a linear model. With only five points this is weak evidence, so read it together with the scatterplot.

The residual plot has points (2, 0.6), (4, -0.7), (6, 1.0), (8, -2.3), and (10, 1.4). They are scattered above and below 0 with no curve, so a linear model is appropriate for these data.

Frequently asked questions

What does a good residual plot look like?

The points are scattered randomly above and below the horizontal line at 0, with no curve or other clear pattern. That means the line captured the form of the relationship and what remains looks like random variation.

Can a residual plot tell me whether the association is positive or negative?

No. The residuals are what remains after the line is subtracted, so the direction of the original relationship is gone. Use the scatterplot, the sign of the slope, or the sign of the correlation for direction.

Why make a residual plot if I already have a scatterplot?

A residual plot makes departures from a line easier to see. On a scatterplot, a slight curve can hide inside a strong upward or downward trend. Removing the trend leaves only the misses, and a curve in them stands out.