AI Glossary / Statistics and probability / Intermediate
Error variance
Definition
Error variance is the variance of the error term in a specified statistical model. In a classical regression model with constant conditional variance, it is commonly written sigma squared and describes variation around the true regression mean. It is often estimated from residuals after fitting the model. It differs from the variance of the outcome itself, the uncertainty of a coefficient estimate, and overall prediction error.
What it means
A regression can explain how average demand changes with price while individual observations still vary around that average. Error variance describes the remaining variability under the model's definition of the error term.
The supplied glossary describes it through the square of the standard error of estimate. In this context, that refers to the regression residual standard deviation and its associated variance estimate. It should not be confused with squaring the standard error of a sample mean or of a particular regression coefficient.
How it works
Write a regression as Y = f(X) + epsilon. If f(X) is the conditional mean, then the error has conditional mean zero. A homoscedastic model assumes Var(epsilon | X) = sigma squared across predictor values. A heteroscedastic model allows that conditional variance to change.
The true errors are usually unobserved because the true regression function is unknown. Fitted residuals, y_i - y-hat_i, are observable substitutes after parameters have been estimated. They are constrained by the fitting process and do not behave exactly like independent copies of the original errors.
For ordinary least squares with n observations and a full-rank fixed design containing p fitted coefficients, a standard estimate is s squared = RSS/(n - p), where RSS is the sum of squared residuals. The intercept counts among those p coefficients when included. Under the correctly specified linear mean model and uncorrelated, equal-variance errors, this is an unbiased estimator of sigma squared. Normality is not required for that unbiasedness, although it supports familiar exact distributional inference.
The square root s is the residual standard deviation, in the original outcome units. The variance is in squared units. Dividing RSS by n instead produces the mean squared training residual, which is a different quantity and is biased downward for the error variance under these classical assumptions.
Check the model before interpreting s squared as a stable noise level. Curvature, changing spread, serial dependence, outliers, and omitted structure can affect residual behavior. Robust coefficient standard errors address certain inference problems but do not automatically make the underlying error variance constant.
Prediction uncertainty for a future observation generally combines uncertainty in the fitted mean with the future observation's error. A residual variance estimate alone is therefore not a complete prediction interval.
Three practical examples
- A demand analyst estimates residual variance to quantify variation around a fitted linear mean relationship.
- An experiment uses a residual mean square in an analysis-of-variance model to estimate a common error variance under its assumptions.
- A monitoring team examines residual spread across operating conditions before deciding whether one constant variance is adequate.
Think of it this way
Think of a trend line running through a cloud of measurements. The line describes the modeled center, while the cloud's spread around that center describes another feature. A line can be estimated precisely with enough observations even when the cloud remains wide.
Worked example
Use an original dataset with predictor values 0, 1, 2, and 3 and outcomes 1, 3, 2, and 4. The least-squares line with an intercept is y-hat = 1.3 + 0.8x.
Its fitted values are 1.3, 2.1, 2.9, and 3.7. The residuals are -0.3, 0.9, -0.9, and 0.3, giving RSS = 0.09 + 0.81 + 0.81 + 0.09 = 1.8.
There are four observations and two fitted coefficients, so the residual degrees of freedom are 4 - 2 = 2. The classical error-variance estimate is 1.8/2 = 0.9 outcome-units squared. The residual standard deviation is the square root of 0.9, approximately 0.949 outcome units.
The mean squared training residual is instead 1.8/4 = 0.45. Its smaller value reflects a different denominator, not evidence of a different dataset or a better model. With only two residual degrees of freedom, this example provides little information about the population variance. The calculations illustrate the distinction between quantities rather than establish that the model assumptions hold.
Illustrative case study
Fictional case: Oak Forecast estimates shipment duration with a linear model and reports one residual standard deviation for all routes. A residual plot shows much larger spread on long routes.
The analyst investigates a variance model or a suitable transformation and checks whether the mean relationship also needs revision. The team evaluates prediction intervals on later shipments. It stops treating one overall error-variance estimate as a guarantee of equal predictive reliability across every route.
Common misconceptions and mistakes
Mistake: equating error variance with the variance of all observed outcomes. Explained mean differences also contribute to outcome variation.
Mistake: treating residuals as the true model errors.
Mistake: forgetting to count the intercept in the fitted coefficient total.
Mistake: using the ordinary n - p formula unchanged for every penalized, nonlinear, or dependent-data method.
Mistake: assuming a low training residual variance proves strong future prediction.
Mistake: reporting variance in the original outcome units instead of squared units.
Business use
Businesses use error-variance estimates to assess unexplained variability, plan experiments, and construct model-based uncertainty measures. The estimate is most informative when accompanied by the residual degrees of freedom, model assumptions, and diagnostic evidence. Its interpretation should distinguish uncertainty about average behavior from variation in individual outcomes. Decisions involving unreliable tails or changing conditions need more than a single average spread estimate.
People also ask
Can error variance vary with predictors?
Yes; this is heteroscedasticity.
Does zero average residual imply zero error variance?
No. Positive and negative residuals can cancel while their squared values remain large.
Does adding predictors always improve the variance estimate?
No. Model complexity, misspecification, and overfitting affect the interpretation and estimation.
Check your understanding
Why is the worked estimate divided by two rather than four?
Answer: The classical calculation adjusts for two fitted coefficients.
Is 0.9 the variance of an estimated slope?
Answer: No. It estimates the model's common error variance; slope uncertainty also depends on the predictor design.
Related terms
- Residual
- Homoscedasticity
- Degrees of freedom
- Mean Squared Error
- residual sum of squares
- standard error of estimate
- heteroscedasticity
- and prediction interval
Learn next
distinguish errors from fitted residuals, inspect residual plots, and derive how error variance and predictor spread jointly determine coefficient uncertainty.
More in Statistics and probability
- Equivalence test - An equivalence test assesses whether an effect lies within prespecified bounds representing differences small enough to be considered practically...
- Error rate per comparison ( PC ) - Error rate per comparison is the probability of falsely rejecting the null hypothesis for a particular comparison when that null is true.
- Error (Statistical error) - Statistical error is the difference between a value obtained through data collection or estimation and the corresponding true population value or other...
- Errors of prediction - Errors of prediction are the differences between observed outcomes and their corresponding predicted values.
- Estimate - An estimate is a value calculated from observed data to represent an unknown quantity, such as a population mean, proportion, total, or model parameter.
- Estimation - Estimation is the process of using observed data to infer unknown quantities, such as population characteristics or model parameters.
Sources
Sources: Howell, Statistical Methods for Psychology glossary, Error variance: https://www.uvm.edu/~statdhtx/methods8/Glossary/Glossary.html . NIST/SEMATECH handbook, Least Squares: https://www.itl.nist.gov/div898/handbook/pmd/section4/pmd431.htm ; Goodness-of-fit metric: https://itl.nist.gov/div898/handbook/pri/section5/pri5992.htm . The four-observation regression is original.
Previous: Error (Statistical error) Next: Errors of prediction