How do L1 (Lasso) and L2 (Ridge) regularization relate to MAP estimation with specific prior distributions?

Quick Overview

Asks which prior distributions on regression weights turn L2 and L1 penalties into maximum a posteriori estimates. Tests deriving a penalty from the negative log-posterior, linking the penalty strength to the noise and prior scale, and explaining where lasso's sparsity comes from.

How do L1 (Lasso) and L2 (Ridge) regularization relate to MAP estimation with specific prior distributions?

Role: Data Scientist

Category: Statistics & Math

Difficulty: medium

Interview Round: Other

How do L1 (Lasso) and L2 (Ridge) regularization relate to maximum a posteriori (MAP) estimation with specific prior distributions? Assume a linear regression with Gaussian noise. For each penalty, say which prior on the weights makes the penalized least-squares estimate a MAP estimate, and what that view tells you about the solutions each penalty produces. ```hint Start from Bayes' rule Write the posterior as likelihood times prior, take the negative log, and see which term each penalty lines up with. ``` ```hint Mode versus mean MAP returns one point of the posterior. Ask whether the property you attribute to the estimate also holds for the rest of the posterior. ``` ### What a Strong Answer Covers - Which prior corresponds to each penalty, with a short derivation from the negative log-posterior. - How the penalty strength maps to the noise variance and the scale of the prior. - Why one penalty produces coefficients that are exactly zero and the other only shrinks them. - What changes if you summarize the posterior by its mean instead of its mode. ### Follow-up Questions - What prior corresponds to elastic net, and how does its MAP estimate behave with correlated features? - The posterior mean under a Laplace prior is not sparse. How would you build a Bayesian model whose posterior puts real probability on a coefficient being exactly zero? - What does the prior view say about standardizing features before fitting ridge or lasso? - How could you choose the penalty strength from a Bayesian standpoint instead of by cross-validation?

Overview: Asks which prior distributions on regression weights turn L2 and L1 penalties into maximum a posteriori estimates. Tests deriving a penalty from the negative log-posterior, linking the penalty strength to the noise and prior scale, and explaining where lasso's sparsity comes from.

Nov 25, 2026
mediumData ScientistOtherStatistics & Math
0
0

How do L1 (Lasso) and L2 (Ridge) regularization relate to maximum a posteriori (MAP) estimation with specific prior distributions?

Assume a linear regression with Gaussian noise. For each penalty, say which prior on the weights makes the penalized least-squares estimate a MAP estimate, and what that view tells you about the solutions each penalty produces.

What a Strong Answer Covers Guidance

  • Which prior corresponds to each penalty, with a short derivation from the negative log-posterior.
  • How the penalty strength maps to the noise variance and the scale of the prior.
  • Why one penalty produces coefficients that are exactly zero and the other only shrinks them.
  • What changes if you summarize the posterior by its mean instead of its mode.

Follow-up Questions Guidance

  • What prior corresponds to elastic net, and how does its MAP estimate behave with correlated features?
  • The posterior mean under a Laplace prior is not sparse. How would you build a Bayesian model whose posterior puts real probability on a coefficient being exactly zero?
  • What does the prior view say about standardizing features before fitting ridge or lasso?
  • How could you choose the penalty strength from a Bayesian standpoint instead of by cross-validation?