How to make a residual plot
-
Paste your data
Paste cells from a spreadsheet or upload a CSV with a number column for X (predictor) and a number column for Y (response), plus a text column for Label if you have it.
-
Check the columns
The residual plot picks its columns for you. Change any of them under Data.
-
Style it and download
Under Style, pick a look, colours, background and size, add a title and source, then download SVG or PNG.
What is a residual plot?
A residual plot shows what is left over after fitting a straight line: each point's residual (observed y minus the fitted y) plotted against x. It is the standard check that a linear model suits the data.
How to read it
The solid line at zero is the fitted line laid flat. Points should scatter evenly above and below it with no shape. A curve or arch in the points (and in the trend line through them) means the relationship is not straight; a fan that widens to one side means the spread changes with x. The dashed lines sit at two residual standard errors, so roughly 1 point in 20 falling outside them is normal; points far beyond them are worth checking.
When to use it
Check whether a straight-line fit leaves a pattern behind. It is one of the correlation charts, which show how two or more measures move together.
To show the relationship itself to an audience, use a Scatter with trend line. To check whether the residuals are normally distributed, a Q-Q plot of the residuals is the better tool.
Tips for a better residual plot
- Look at the residual plot before you trust R squared; a high R squared can hide a clear curve.
- If the points fan out, try a log transform of y and fit again, rather than reading p-values from a model with unequal spread.
- Investigate large residuals one by one (a typo, a different batch, a real effect) instead of deleting them to tidy the fit.
Data you need
One row per item with a number column for X (predictor) and a number column for Y (response), plus a text column for Label if you have it. Column names can be anything; the chart maker matches columns by type, and you can change the match under Data.
| Tree | Trunk diameter (cm) | Height (m) |
|---|---|---|
| T01 | 65.2 | 33.7 |
| T02 | 44.8 | 31.0 |
| T03 | 47.1 | 32.0 |
| T04 | 49.9 | 29.4 |
| T05 | 49.2 | 33.0 |
| T06 | 57.2 | 31.0 |
| T07 | 79.4 | 33.6 |
| T08 | 56.7 | 30.8 |
Other charts for the same data
More correlation charts
Questions, answered
- What is a residual plot?
- A residual plot shows what is left over after fitting a straight line: each point's residual (observed y minus the fitted y) plotted against x. It is the standard check that a linear model suits the data.
- How do you read a residual plot?
- The solid line at zero is the fitted line laid flat. Points should scatter evenly above and below it with no shape. A curve or arch in the points (and in the trend line through them) means the relationship is not straight; a fan that widens to one side means the spread changes with x. The dashed lines sit at two residual standard errors, so roughly 1 point in 20 falling outside them is normal; points far beyond them are worth checking.
- How do I make a residual plot?
- Paste your data into the chart maker with a number column for X (predictor) and a number column for Y (response), plus a text column for Label if you have it. The residual plot draws as you type. Then pick a look and a size and download it as SVG or PNG.
- When should I use a residual plot?
- Check whether a straight-line fit leaves a pattern behind. It belongs to the correlation family of charts, which show how two or more measures move together. To show the relationship itself to an audience, use a Scatter with trend line. To check whether the residuals are normally distributed, a Q-Q plot of the residuals is the better tool.
- Is this residual plot maker free?
- Yes. It is free with no sign-up, your data stays in your browser, and you can download the residual plot as SVG or PNG.