Ridge regression
Ridge adds a squared coefficient penalty to a linear prediction model. It reduces sensitivity to poorly determined directions, while introducing bias. The intercept is usually left unpenalised.
2.1 Objective, intercept and solution
Let have rows , collect the targets, be the coefficient vector and the intercept. Centre each feature and the target using training means and ; write the centred arrays as .
If the model explicitly has no intercept, use directly without centring. Penalising an augmented intercept coefficient is a different problem. For heterogeneous physical feature units, scale features first so that the isotropic penalty has a meaningful interpretation.
2.2 Shrinkage and prediction variance
Past papers · DA 2024–2026 (3 papers): 1 question, 2 marks
Use the compact SVD , with positive singular values on the diagonal of and rank . Singular-value algebra: see Engineering Mathematics.
As , the solution approaches the minimum-norm least-squares solution. As , coefficients tend to zero; an unpenalised intercept tends to . Directions with smaller are shrunk more strongly. Individual coefficients need not decrease monotonically in magnitude when predictors are correlated; the total coefficient norm is nonincreasing with .
Last-minute recall
- Ridge uses a squared penalty.
- Centre the data to leave the intercept unpenalised.
- Positive regularisation makes the coefficient system invertible.
- Loss normalisation changes the numerical regularisation parameter.
- Shrinkage reduces noise amplification along small-singular-value directions.
- A smaller variance does not guarantee a smaller total prediction error.