2.6.10 · D5Model Evaluation & Selection

Question bank — Regression metrics (MAE, MSE, RMSE, MAPE)

1,991 words9 min readBack to topic

Before we start, three symbols you must already own from the parent note:

  • = the true value for sample (what actually happened).
  • = the predicted value for sample (what the model guessed).
  • = the residual, the gap between them. Positive means the model under-predicted; negative means it over-predicted.

And the four recipes, stated once so nothing below is left to guess. Each takes the residuals and squashes them to one number:

Every metric below is just one of these recipes viewed from a different angle.


Why RMSE is never smaller than MAE

Several traps below hinge on the inequality . Let's see why, not just assert it. The whole difference is one choice: MAE runs each error through a straight line (), while RMSE runs it through a bowl-shaped parabola () before averaging and un-squaring.

Figure — Regression metrics (MAE, MSE, RMSE, MAPE)

Reading the figure. The horizontal axis is the raw residual ; the vertical axis is the penalty that each metric applies to that residual before averaging. The cyan V-shape is — the exact quantity MAE averages — and it grows in a straight line as the error grows. The amber curve is — the exact quantity MSE averages — and it is a parabola because squaring a bigger number grows faster and faster. So the two curves are literally the two penalty rules; nothing is metaphorical here.

The formal step (Jensen's inequality). Write for the absolute errors, and let mean "average over the samples". Because the squaring function is convex (it curves upward everywhere), Jensen's inequality says the average of the squares is at least the square of the average: The left side is exactly (average of ); the right side is exactly (square of the average of ). So . Take the square root of both non-negative sides: Geometrically that is the picture: averaging points on the upward-curving amber bowl lands above the bowl evaluated at the average error. The two sides meet only when every is identical, because then there is no spread for the curvature to exaggerate.


True or false — justify

MAE and RMSE are always reported in the same units as the target variable.
True — MAE averages and RMSE square-roots back out of the squaring, so both land in the target's own units (dollars, metres). MSE alone lives in squared units.
RMSE can be smaller than MAE for some datasets.
False — by Jensen's inequality , so always, with equality only when every error has identical magnitude.
If RMSE equals MAE exactly, all the absolute errors must be equal.
True — equality in holds only when there is zero spread in the values, i.e. every prediction is off by the same amount.
Minimising MSE and minimising MAE always pick the same "best constant prediction".
False — the constant minimising MSE is the mean of the targets, while the constant minimising MAE is the median; these differ whenever the data is skewed.
A model with lower MAE than a rival is guaranteed to have lower MSE too.
False — concretely, model A has errors giving MAE , MSE ; model B has errors giving a higher MAE ... wait — instead take A (MAE , MSE ) versus B (MAE , MSE ): B has both lower MAE and lower MSE, but swap to A (MAE , MSE ) versus B (MAE , MSE ) — now A wins on MAE yet loses on MSE, proving lower MAE does not imply lower MSE.
MAPE is dimensionless, so it lets you fairly compare a house-price model against a temperature model.
False — dimensionless is necessary but not sufficient; each percentage error is divided by that problem's , so a problem whose typical true values are near zero (or spread over a very different range) will inflate MAPE for reasons unrelated to model quality, so the "fair comparison" can be illusory.
Squaring errors in MSE is done mainly to remove negative signs.
False — removing signs is a side effect; the point is the quadratic penalty that makes a error hurt more than a error, not more.
MSE being differentiable everywhere is why gradient descent prefers it to MAE during training.
True — has a kink (no clean derivative) at , whereas is smooth, giving gradient descent a well-defined slope everywhere.
MAPE treats a prediction of (truth ) and a prediction of (truth ) as equally wrong.
True — both have absolute error and the same true value in the denominator, so each scores ; the notorious MAPE asymmetry appears only when you compare across different true values (a fixed absolute error is a bigger percentage of a small than of a large one).

Spot the error

"MAPE is undefined only when a prediction equals zero."
Wrong — the denominator is , the true value, so MAPE blows up when a true value is zero, regardless of the prediction.
"To fix negative residuals I can just drop the absolute value in MAE, since squaring in MSE removes signs anyway."
Wrong — dropping in MAE lets positive and negative errors cancel, giving a near-zero score for a terrible model; the whole purpose of is to stop that cancellation.
"RMSE mean of the RMSEs, so I can average per-sample RMSE values."
Wrong — you must square, then average, then root; averaging square roots first is not the same operation and understates the outlier penalty ().
"Since MAE is robust to outliers, I should also train my network by minimising MAE for cleaner gradients."
Wrong — MAE is robust for reporting, but its constant gradient gives no sense of how far off you are, so optimisation can stall; see loss functions.
"A low MAPE guarantees a low RMSE."
Wrong — they answer different questions; a model can hit small percentages on large yet carry a big absolute miss on one huge value, keeping MAPE low but RMSE high.
"Because RMSE and MAE are both in dollars, RMSE minus MAE is meaningless."
Wrong — the gap is a legitimate, unit-carrying diagnostic: a large gap signals a few dominant outlier errors, a near-zero gap signals uniform errors.

Why questions

Why does one catastrophic prediction move MSE far more than MAE?
Because MSE squares each error before averaging, so a large grows quadratically and dominates the sum, whereas MAE only sums the magnitudes linearly.
Why is RMSE, not MSE, the usual number quoted in model comparison benchmarks?
RMSE keeps MSE's outlier sensitivity but reports in the target's real units, so it is directly interpretable and comparable to MAE across papers.
Why can MAPE penalise under-prediction and over-prediction unequally?
With true value fixed at , the ratio is bounded for under-prediction — as it tops out at (i.e. ) — but for over-prediction it is unbounded; e.g. truth : predicting scores at most, while predicting already scores , so over-predictions can be punished far harder.
Why does MAE effectively "vote for the median" while MSE "votes for the mean"?
Minimising summed absolute deviations lands on the middle-ranked point (the median), while minimising summed squared deviations is pulled toward the balance point of mass (the mean), which outliers can drag.
Why should you scale or normalise targets before comparing MSE across two problems?
MSE's magnitude depends on the target's units and range, so a raw MSE on house prices dwarfs one on temperatures for reasons unrelated to model quality — see feature scaling.
Why does the MAE-vs-MSE disagreement tie back to the bias-variance tradeoff?
Choosing a squared penalty (MSE) tolerates many small biased misses but punishes high-variance blow-ups, so your loss choice quietly encodes how much variance you are willing to trade for bias.

Edge cases

If every prediction is perfect, what do all four metrics read?
All read — MAE, MSE, RMSE become because every , and MAPE is provided no true value is zero (else it is undefined).
A dataset has one true value ; which metrics survive?
MAE, MSE and RMSE are all fine, but MAPE is undefined because it divides by — use a symmetric variant like sMAPE or switch metrics.
What is sMAPE (symmetric MAPE) and why does it help?
It replaces the denominator with the average of true and predicted magnitude, , which stays finite unless both and are zero and treats over- and under-prediction more evenly.
Does a negative true value break MAPE, and does the sign matter?
The absolute value in the denominator strips the sign, so a true value of behaves like for scaling; MAPE is only undefined at , but negative targets still make the "percentage of true value" reading harder to interpret intuitively.
What happens to MAPE when the true value is tiny but nonzero, say ?
Even a small absolute error is divided by a near-zero denominator, producing an enormous percentage that can single-handedly dominate the average — MAPE is unstable near zero.
For a single sample (), how do RMSE and MAE relate?
With one point RMSE MAE — the inequality collapses to equality because there is no spread across samples.
If all errors have the same magnitude but alternating signs, does MSE notice the signs?
No — squaring erases the sign, so and give identical MSE, RMSE and MAE; sign information is deliberately discarded.
Recall Quick self-test

RMSE MAE, with equality when ::: all absolute errors are equal (zero spread). MAPE breaks down when ::: a true value is zero (or near zero). MSE is preferred for training because ::: it is smooth/differentiable everywhere, unlike the kink in . MAE-minimising constant is the ::: median; MSE-minimising constant is the mean.