Regression residuals
A residual is r=y minus fitted y-hat, in the same observation order. It need not equal the unobserved population error.
On this page 8 sections
01Match each observation to its fitted prediction#
Match each observation to its fitted prediction. Here the differences are , , and .
A residual uses the observed response minus the fitted prediction. Keep the same record order in all three vectors.
In record order, , . Give .
Show answer and explanation
Residuals: .
02An observation below its prediction has a negative residual#
An observation below its prediction has a negative residual. Squaring or taking absolute values loses that sign; those are different quantities.
In record order, , . Wrong from . Repair .
Show answer and explanation
Residuals: .
03Residuals use an estimated prediction hat y#
Residuals use an estimated prediction . The population error subtracts the true conditional mean. The two differences need not match.
For a fitted rule at , prediction is . If the observed response is , the residual is .
Fitted . In record order, , . Give .
Show answer and explanation
; .
Subtract the fitted prediction from the observation. Keep the sign and record order.
- Compute residuals from fitted predictions and observations.
Further questions
How can a linear score produce a probability instead of an unrestricted prediction?
Sources & further reading
- [1]Penn State STAT 501, Notation Used in the Course ↗Textbook · Book
- [2]