Assumptions of Linear Regression
Explore how to diagnose key assumptions of linear regression models by analyzing residuals for patterns in linearity, variance, independence, and distribution. Understand how each diagnostic reveals model limitations and guides improvements in predictive accuracy and interpretation.
A house-price model can report a modest average error while still underpredicting homes above $800,000 and overpredicting homes near $300,000. The single error number hides where the model fails. Residual diagnostics inspect the pattern of residuals, where each residual is the actual price minus the predicted price, so we can decide whether a straight-line model is a reasonable approximation.
Linear regression does not require a perfect dataset. Instead, four checks reveal whether its errors follow patterns that make predictions or conclusions less reliable:
Linearity means the relationship leaves no curved pattern in the residuals.
Homoscedasticity means residuals keep roughly the same vertical spread across predictions.
Independence means one row’s residual does not systematically resemble nearby rows’ residuals.
Normality of residuals means the residual distribution is roughly bell-shaped.
A diagnostic plot does not automatically reject a model. It gives us evidence to investigate. A random-looking cloud around zero supports the linear approximation. A visible pattern tells us what the model has missed.
Curvature reveals a nonlinear relationship
Because residuals show where predictions miss, a residuals-versus-predicted plot is the first check for linearity. The horizontal axis contains predicted values, written as
A curved band means the model makes errors in a predictable direction. For example, a straight line fitted to a curved relationship may ...