Álgebra 1Data and StatisticsS-ID.B.6

Lines of Fit and Residuals

Fit a line to data and use residuals to judge the fit.

Sin empezar Ir a la práctica

Esta lección aún no está traducida. Por ahora se muestra en inglés; la versión en español está en camino.

A line of fit summarizes a scatter plot with an equation, which is a linear model you can use to predict. How well does it fit? Look at the residuals: how far each actual point is from the line.

Por qué funciona

For each data point, the line predicts $\hat{y}$ (read “y-hat”) at that $x$. The residual is $y - \hat{y}$, actual minus predicted. A positive residual means the point is above the line, a negative one means below, and $0$ means on it. The least-squares line is the line that makes the sum of the squared residuals as small as possible; squaring keeps positive and negative misses from canceling and weighs big misses more. A good linear fit leaves residuals scattered randomly around $0$; a curved pattern in the residuals says a line is the wrong shape.
Green segments are positive residuals (points above the line); red are negative. Drag a point and watch the line and the residuals change.

Idea clave

Residual $= y - \hat{y}$ = actual $-$ predicted. Small residuals with no pattern mean the line fits well.

Worked examples

Ejemplo resuelto: Compute a residual

A line of fit is $\hat{y} = 4x + 48$. A student who studied $5$ hours scored $70$. Find the residual.
  1. Predicted: $\hat{y} = 4(5) + 48 = 68$.
  2. Residual: $70 - 68 = 2$.

Respuesta: $2$: the student scored $2$ points above the prediction.

Ejemplo resuelto: Read a residual pattern

Residuals in order of $x$: $-4, -1, 2, 3, 2, -1, -4$. Is the line a good model?
  1. The residuals go negative, then positive, then negative: a curved pattern, not random scatter.

Respuesta: No: the data bends, so a curve would fit better.

Error común

Computing residuals as predicted minus actual, which flips every sign. Residual means actual minus predicted, so a point above the line has a positive residual. Check against the picture: above the line should give a positive number.

Práctica

Apruebas con 3 respuestas correctas, las 2 últimas seguidas. Cada respuesta correcta da 2 XP.

Cargando la práctica…

Se apoya en

Lleva a

Fuentes y lecturas

  • OpenStax, Introductory Statistics, chapter 12 Linear Regression and Correlation
  • Common Core State Standards for Mathematics, S-ID.B.6: fit a function to data, use it to solve problems, and assess the fit by plotting and analyzing residuals