Explain L1 vs L2 and ridge vs lasso
UpstartData Scientist · OnsiteLast updated
This question evaluates understanding of regularization techniques in Machine Learning—specifically distinctions between L1 and L2 norms and their instantiation as Lasso and Ridge regression—covering effects on objective functions, parameter sparsity, geometric intuitions, handling of correlated features, and the role of feature scaling.
Explain the differences between:
- L1 vs L2 regularization (how they change the objective, geometry/intuitions, and typical effects on learned parameters).
- Ridge vs Lasso regression (relationship to L2/L1, impact on feature selection/sparsity).
Also discuss practical considerations:
- when you would choose ridge vs lasso (or elastic net)
- what happens with correlated features
- why feature scaling/standardization matters
(Optionally) define what a likelihood is and how it relates to loss functions such as negative log-likelihood.
Solution walkthrough is for members
Get the full walkthrough with reference code and complexity analysis, plus Kitty Coach at 300 messages a day. Hints, the code runner and community answers stay free.