Concept
Bias and variance
Two kinds of model error: too simple (underfitting) or too tied to the training data (overfitting).
Also called
- Underfitting
- High bias
- Good fit
- Balanced
- Overfitting
- High variance
The model is
- Underfitting
- Too simple
- Good fit
- Just complex enough
- Overfitting
- Too tied to examples
On training data
- Underfitting
- Poor
- Good fit
- Good
- Overfitting
- Excellent
On new data
- Underfitting
- Poor
- Good fit
- Good
- Overfitting
- Poor
What helps
- Underfitting
- A richer model, more training
- Good fit
- Keep monitoring
- Overfitting
- More varied data, a simpler model
| Compare | Underfitting | Good fit | Overfitting |
|---|---|---|---|
| Also called | High bias | Balanced | High variance |
| The model is | Too simple | Just complex enough | Too tied to examples |
| On training data | Poor | Good | Excellent |
| On new data | Poor | Good | Poor |
| What helps | A richer model, more training | Keep monitoring | More varied data, a simpler model |
1 / 3
Also called
- Underfitting
- High bias
- Good fit
- Balanced
- Overfitting
- High variance
The model is
- Underfitting
- Too simple
- Good fit
- Just complex enough
- Overfitting
- Too tied to examples
| Compare | Underfitting | Good fit | Overfitting |
|---|---|---|---|
| Also called | High bias | Balanced | High variance |
| The model is | Too simple | Just complex enough | Too tied to examples |
2 / 3
On training data
- Underfitting
- Poor
- Good fit
- Good
- Overfitting
- Excellent
On new data
- Underfitting
- Poor
- Good fit
- Good
- Overfitting
- Poor
| Compare | Underfitting | Good fit | Overfitting |
|---|---|---|---|
| On training data | Poor | Good | Excellent |
| On new data | Poor | Good | Poor |
3 / 3
What helps
- Underfitting
- A richer model, more training
- Good fit
- Keep monitoring
- Overfitting
- More varied data, a simpler model
| Compare | Underfitting | Good fit | Overfitting |
|---|---|---|---|
| What helps | A richer model, more training | Keep monitoring | More varied data, a simpler model |
- 1The training data has many examples of group A and few of group B.
- 2The model learns group A well, so its results are accurate for group A.
- 3The model learned little about group B, so its results are less accurate for group B.
Step by step
- 1The training data has many examples of group A and few of group B.
- 2The model learns group A well, so its results are accurate for group A.
- 3The model learned little about group B, so its results are less accurate for group B.
What it is
Here bias and variance are two ways a model can be wrong. Bias is error from a model that is too simple. It misses real patterns, so it does badly on training data and on new data. This is underfitting. Variance is error from a model that is too sensitive to its training data. It learns the noise and memorizes examples, so it does well on training data and badly on new data. This is overfitting. A good fit sits between the two.
What it is
Do not mix this up with bias in the sense of unfairness. The same word covers both, and the exam uses both. Unfair bias comes from the data, such as too few examples of one group. It can show up as a model that is accurate for one demographic group and inaccurate for another. Overfitting and underfitting hurt accuracy for everyone.
You find both by comparing results on training data with results on new data, and by comparing results across groups.
Remember
- High bias leads to underfitting: poor on training data and on new data.
- High variance leads to overfitting: strong on training data, poor on new data.
- A gap between training results and new-data results points to overfitting.
- A good fit has low error on both.
Remember
- Too few examples of a group can make the model less accurate for that group.
- Statistical bias (too simple) is not the same as unfair bias. Read the question for which one.
On the exam
- “Excellent on training data, poor on new data” points to overfitting, which is high variance.
- “Poor results on training data and on new data” points to underfitting, which is high bias.
- “Less accurate for one demographic group” points to unfair bias, often from unbalanced data.
Do not mix it up with
- Characteristics of good datasetsA model learns from its data, so the data must include everyone, vary enough, come from good sources and be balanced.
- Detecting and monitoring biasWays to find and keep watching for bias, untrustworthy output and untruthful output.
- Model performance metricsAccuracy, precision, recall, F1 and AUC-ROC score classifiers. MAE, RMSE and R squared score number predictions.