October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PCOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk4 min

What Is the Bias–Variance Tradeoff? Underfitting and Overfitting Explained

The bias–variance tradeoff explains how models can miss real patterns or fit noise. Learn to diagnose underfitting and overfitting with validation data.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The bias–variance tradeoff is a way to understand why a model can perform poorly either because it is too simple to capture a real pattern or because it fits quirks in its training examples too closely. The practical aim is not to minimize training error at any cost, but to choose a model that predicts well on new data.

What do bias and variance mean?

Bias is systematic error caused by assumptions or a model class that cannot represent the pattern the task requires. A model with high bias tends to make similar mistakes even when trained on different samples.

As an Amazon Associate I earn from qualifying purchases.

Variance describes how much a model’s learned predictions or decision boundary change when the training sample changes. A high-variance model is sensitive to which examples it happened to see. Variance is not itself a measure of whether predictions are correct: a model can be consistently wrong or inconsistently right.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

In the familiar squared-error regression setting, expected prediction error can be expressed as squared bias plus variance plus irreducible noise, often written bias² + variance + σ². This decomposition depends on that setup and should not be treated as an identical formula for every loss, classifier, or modern learning system. Stanford’s Applied Statistics teaching chapter covers the decomposition and model evaluation.

How underfitting and overfitting differ

Underfitting: too little flexibility to capture the signal

Underfitting occurs when a model misses meaningful structure in the data. It is commonly associated with high bias. For example, if the true relationship between two variables is curved, a straight line may systematically miss that curve. The line could make similar errors across different training samples because its form is too restricted.

Overfitting: learning sample-specific detail

Overfitting occurs when a model fits details particular to its training examples—including noise—in a way that can hurt predictions on new examples. It is commonly associated with high variance. A highly flexible curve might pass close to individual noisy observations, reducing its training error while changing substantially if the sample changes.

Rank #2
Sale
Hands-On Machine Learning with Scikit-Learn, Keras, and TensorFlow: Concepts, Tools, and Techniques to Build Intelligent Systems
  • Use scikit-learn to track an example ML project end to end
  • Explore several models, including support vector machines, decision trees, random forests, and ensemble methods
  • Exploit unsupervised learning techniques such as dimensionality reduction, clustering, and anomaly detection
  • Dive into neural net architectures, including convolutional nets, recurrent nets, generative adversarial networks, autoencoders, diffusion models, and transformers
  • Use TensorFlow and Keras to build and train neural nets for computer vision, natural language processing, generative models, and deep reinforcement learning

These are diagnostic patterns, not labels determined by a parameter count. A model with many parameters is not automatically overfit, and zero training error alone does not prove that it is. Stanford’s Information Retrieval text explains that variance concerns inconsistency across training sets, whether the resulting decisions are correct or not, and that high-variance methods are prone to learning noise.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Why complexity can help, then hurt

In the classical teaching picture, increasing model flexibility can initially improve predictions by letting the model capture structure that a simpler model misses. Beyond some point, additional flexibility can make it easier to fit sample-specific details, increasing sensitivity to the training data. This produces the familiar U-shaped picture of generalization error: high error from underfitting at one end, a better balance in the middle, and higher error from overfitting at the other.

Stanford’s archived CS229 lecture transcript uses this diagram to explain the classical relationship between complexity, generalization error, high bias, and high variance. It is a teaching model for reasoning about a common pattern, not a guarantee that every algorithm follows the same curve. The useful balance depends on the task and the data.

How to diagnose the problem with data

Compare candidate models on training data and on held-out validation data, using the metric that matters for the task. A large gap—with training performance much better than validation performance—can be a warning sign of overfitting. Poor performance on both may point to underfitting, but can also reflect data quality problems, measurement noise, or a mismatch between the evaluated data and the intended use.

  • Training versus validation: Look at both results and their gap; training performance alone cannot establish generalization.
  • Stability across folds or samples: Large changes in performance across cross-validation folds or repeated samples can indicate sensitivity to the data split.
  • Flexibility and regularization: Consider whether the model can represent the pattern and whether constraints or regularization affect its fit.
  • Target metric and data: Choose using validation performance on the metric you care about, and check that evaluation data resembles the population where predictions will be used.

Stanford’s Applied Statistics chapter distinguishes the roles of training, validation, and test data and discusses cross-validation as a tool for model selection.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

How to choose a model without contaminating the final test

  1. Fit candidates on training data. Use training data to estimate each model’s parameters.
  2. Select complexity on validation data or by cross-validation. Compare candidate models using the target metric; do not use the final test set to choose among them.
  3. Reserve the test set for final assessment. After model selection is complete, evaluate the chosen approach on data that played no part in fitting or selection. This keeps the final estimate meaningfully separate from the decisions that produced the model.

These roles matter because repeatedly checking a test set and adjusting the model in response turns that set into part of the selection process. A separate test evaluation is most informative when the test data has remained outside those choices.

Why the classical curve is not a law

Some high-capacity models and datasets show a pattern called double descent: test risk may rise near the point where a model can interpolate the training data, then fall again as capacity increases further. Belkin, Hsu, Ma, and Mandal describe this behavior in their 2019 paper, “Reconciling modern machine learning practice and the bias-variance trade-off.” Their account extends the textbook U-shaped picture; it does not mean that overfitting is impossible or that validation is unnecessary.

As the authors put it, “The classical thinking is concerned with finding the ‘sweet spot’ between under-fitting and over-fitting.” That remains a useful starting point, provided the curve is understood as a classical pattern rather than a universal rule.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Crashes, No Sound, or Screen Glitches?Free driver scan
Windows Errors? Fix Them Before They SpreadFree repair scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.