Evaluation Metrics for Linear Regression
Evaluation Metrics for Linear Regression
π In regression, we measure how close predicted values are to actual values .
πΉ 1. Mean Squared Error (MSE)
π Interpretation:
- Penalizes large errors heavily
- Lower MSE → better model
πΉ 2. Root Mean Squared Error (RMSE)
π Interpretation:
-
Same units as
- Easier to understand than MSE
πΉ 3. Mean Absolute Error (MAE)
π Interpretation:
- Measures average error
- Less sensitive to outliers
πΉ 4. R-Squared (R^2) -Coefficient of Determination
πΉ Definition
The R-squared () value measures how well the regression model explains the variability of the data.
πΉ Formula
Where:
π 1. SSR (Sum of Squared Residuals)
- Also called Sum of Squared Errors (SSE)
- Measures unexplained variation
- Error between actual and predicted values
π 2. SST (Total Sum of Squares)
- Measures total variation in data
- Deviation of actual values from mean
πΉ Interpretation
- Measures goodness of fit
- Range:
| Meaning | |
|---|---|
| Perfect fit | |
| Model explains nothing | |
| Partial explanation |
πΉ Key Insight
π It tells:
“How much of the variation in
πΉ 5. Adjusted R-Squared
Where:
- = number of predictors
π Useful when comparing models
πΉ 6. Residual Sum of Squares (RSS)
π Total squared error
πΉ 7. Total Sum of Squares (TSS)
π Total variation in data
πΉ 8. Explained Sum of Squares (ESS)
π Variation explained by model
π Important Relation:
πΉ 9. Mean Absolute Percentage Error (MAPE)
π Interpretation:
- Error in percentage
- Useful in business applications
πΉ 10. Residual Analysis (Conceptual)
π Residual:
Used to check:
- Linearity
- Constant variance
- Model assumptions
πΉ 11. Summary Table
| Metric | Formula | Use |
|---|---|---|
| MSE | squared error | Penalizes large errors |
| RMSE | sqrt(MSE) | Interpretable |
| MAE | absolute error | Robust |
| goodness of fit | Explained variance | |
| RSS | total error | Model fit |
| MAPE | % error | Business |
Key Insights (From ML Perspective)
- Loss function (MSE) → used during training
- Metrics → used for evaluation
- are important metrics
- Error → difference between actual & predicted
-
Good model → low error, high
Comments
Post a Comment