← Iris

Points 0
--
Method Linear
y = ax + b
Click to add points · Drag to move them
Residuals
Presets:

Least squares

Curve fitting finds the function that best matches scattered data. The least squares method minimizes the sum of squared residuals — the vertical distances between each data point and the fitted curve. For linear regression, this has a closed-form solution. For other curves, the same principle applies, often via transformation or iterative methods.

R-squared

The coefficient of determination (R²) measures how much variance in the data the model explains. R² = 1 means a perfect fit; R² = 0 means the model does no better than a horizontal line at the mean. A high R² with a polynomial may indicate overfitting rather than true understanding.

Anscombe’s quartet

Four datasets with identical linear regression statistics (same mean, variance, correlation, and regression line) but visually very different distributions. Francis Anscombe constructed them in 1973 to demonstrate the importance of graphing data before analyzing it.