Skip to content
p.mba

Type to search tools, guides, glossary terms, frameworks, formula sheets and pages.

Menu

Glossary · Data Science & AI

Bias-Variance Tradeoff

Also called: bias-variance decomposition

The tension between models too simple to capture real patterns (high bias) and models so flexible they chase noise (high variance).

Definition

A model's expected prediction error on new data can be split into squared bias, variance and irreducible noise. Bias is error from overly rigid assumptions, such as fitting a straight line to a curved relationship; variance is error from sensitivity to the particular training sample, typical of very flexible models. Making a model more complex usually lowers bias but raises variance, so total error is lowest at an intermediate level of complexity. Cross-validation, regularization and more training data are the standard ways to find or shift that balance.

Formula

E[(y−f^(x))2]=Bias[f^(x)]2+Var⁡[f^(x)]+σ2\mathbb{E}\big[(y - \hat f(x))^2\big] = \text{Bias}\big[\hat f(x)\big]^2 + \operatorname{Var}\big[\hat f(x)\big] + \sigma^2
TeX source
\mathbb{E}\big[(y - \hat f(x))^2\big] = \text{Bias}\big[\hat f(x)\big]^2 + \operatorname{Var}\big[\hat f(x)\big] + \sigma^2

Worked example

Hypothetical: predicting store sales from temperature, a straight line misses a summer peak (high bias), while a 15th-degree polynomial fits last year perfectly but swings wildly on new weeks (high variance). A quadratic fit gives the lowest error in cross-validation.

Try it in a tool

  • Overfitting: When a model learns the noise and quirks of its training data so closely that it performs poorly on new data.
  • Cross-Validation: Estimating how well a model will predict new data by repeatedly training on part of the data and testing on the part held out.
  • Machine Learning: Methods that let computers learn patterns from data to make predictions or decisions without being explicitly programmed with rules.
  • Supervised Learning: Machine learning that trains a model on examples with known answers (labels) so it can predict the answer for new cases.

Courses

More in Data Science & AI

All glossary terms