Train points Test points Fitted model ŷ(x)
⚠ Couldn't load the 3D engineThree.js failed to load from the CDN. Check your connection and reload.

Predictive Modeling: Bias-Variance Regression Lab

This simulation builds predictive models the way a data scientist actually validates them: fit a polynomial regression of any complexity to noisy synthetic data, then check whether it generalizes. Points are split into a training set the model learns from and a held-out test set it never sees during fitting, rendered in 3D on separate planes so the split is visible at a glance. Pick the true underlying relationship — linear, quadratic, or sinusoidal — dial in noise, and slide model complexity from a straight line to a degree-9 polynomial while live train/test mean-squared-error and test R² reveal the exact moment a model stops explaining the pattern and starts memorizing the noise: the bias-variance tradeoff that governs every real forecasting and regression system.