08 - regression metrics
- for regression, there isn't a simple right/wrong but a residual/error:
- the mean absolute error (MAE) takes the absolute value of each error:
- it is easily interpreted as an average deviation from the actual value
- the mean squared error (MSE) takes the squares of the errors:
-
it is less directly interpretable but punishes large errors heavily
-
MAE is more robust to outliers whereas MSE is more sensitive to large errors
the root mean square error (RMSE) takes the square root of MSE:
- now the units back to the original
- it retains MSE's emphasis on larger errors while being easier to interpret
-
a model could naively predict
, so the value helps compare the model against that baseline -
if
then the predictions are perfect -
if
then the model is doing no better than simply predicting for everything -
if
, it is performing worse than the mean-prediction baseline -
note:
loss function vs evaluation metric
-
a loss function is what the algorithm optimises
-
an evaluation metric is what is used to judge the model performance
-
they can be the same, ie. training loss = MSE and evaluation loss = MSE
-
but they needn't be, eg. training optimises MSE, evaluation optimises MAE, RMSE,