
Ever wondered how to pick the best features for a machine learning model?
Image: Balkiss.hamad, CC BY-SA 4.0, via Wikimedia Commons
Ever wondered how to pick the best features for a machine learning model?
Imagine you're trying to predict house prices based on various features like size, location, and age. You have too many features, and some might not be useful at all.
Think of Lasso as a tool that helps you find the most important features by shrinking less important ones to zero, making your prediction model simpler and easier to understand.
Example
If you're predicting house prices and have features like square footage, number of bedrooms, and color of the front door, Lasso might decide that square footage and number of bedrooms are important, while the color of the front door isn't, effectively removing it from the model.
Remember this
Lasso helps you focus on the most important features, simplifying your model and potentially improving its accuracy.
Text adapted from Wikipedia, licensed under CC BY-SA 4.0.
LASSO uses L1 to do feature selection by driving coefficients to exactly zero
Why do some numbers disappear when solving complex problems?
Akaike information criterion
How do we choose the best model for our data?
Ridge regression
Why do straight lines sometimes fail to fit our data perfectly?
L1 vs L2 regularization: L1 gives sparsity (feature selection), L2 gives small weights
L1 regularization: L1 = L2 + sparsity; L2 regularization: L2 = L1 + small weights
Batch normalization
Batch normalization formula: Y = (X - μ) / σ * γ + β
Regression analysis
Linear regression equation: ŷ = β0 + β1X
Swipe through more Machine Learning concepts
Open Pocket Polymath