Train, validate and test
Data are split: one part trains the model, another tunes its settings, and a third, which the model never saw, measures real performance.
Measuring only on training data rewards memorization.
A model that predicts the training data very well can fail on new data. This mini-course covers what separates a useful model from one that memorizes: splitting data, measuring with deviance, validating out of sample, explaining and checking fairness.
By the end of this mini-course you will be able to:
Data are split: one part trains the model, another tunes its settings, and a third, which the model never saw, measures real performance.
Measuring only on training data rewards memorization.
For claim frequencies, the Poisson deviance measures how far predictions \(\mu_i\) are from observations \(y_i\). Lower is better:
When \(y_i=0\), the first term is zero.
Explainability techniques, such as SHAP values and partial dependence plots, show how much each variable contributes. Without them, a complex model is hard to defend to a client or a regulator.
SHAP values split the prediction among the variables.
A variable can act as a proxy for a characteristic that should not be used. And a model is no better than its data. The U.S. modeling standard of practice, ASOP 56, applies since October 2020, and the data quality standard, ASOP 23, since April 2017.
Both standards come from the U.S. Actuarial Standards Board; in Mexico they serve as a reference for good practice.
Six policies with observed claims of 0, 1, 0, 2, 0 and 1 in one year. Model A predicts the mean, 0.667, for all of them; model B uses their characteristics and predicts 0.3, 0.9, 0.4, 1.6, 0.3 and 0.9. A third model C memorizes: it predicts exactly what was observed. The next year the same policies have 1, 0, 0, 1, 0 and 2 claims.
In sample, model C looks perfect. Out of sample it is the worst, at 10.66, because it learned the noise of the observed year. Model B beats the mean on new data too: it learned something from the characteristics. For C, a floor of 0.01 was used on zero predictions.
Choose one answer per question: you will see right away whether it is correct and why. At the end, check your score. Nothing is stored or sent.
Official sources and reference texts. The numerical examples are illustrative.
On actuaria.mx