Homoskedastic (also spelled homoscedastic) describes a condition in regression analysis in which the variance of the residuals (error term) is constant across all values of the predictor(s). In other words, the spread of the residuals around the fitted line is roughly the same for low, medium and high values of the independent variables. Homoskedasticity is one of the classical linear regression assumptions and helps make ordinary least squares (OLS) inference straightforward and reliable. (Source: Investopedia)
Key takeaways
– Homoskedasticity: constant variance of regression errors across observations.
– Heteroskedasticity: non‑constant error variance (variance changes with predictor values or over groups).
– OLS point estimates remain unbiased under heteroskedasticity, but standard errors (and thus t/Z tests and confidence intervals) can be wrong unless corrected.
– Diagnose with residual plots and formal tests (Breusch–Pagan, White).
– Fixes include transforming variables, using weighted least squares (WLS), or using heteroskedasticity‑consistent (robust) standard errors.
(Source: Investopedia and standard econometrics texts)
How homoskedasticity works (intuition)
– Regression model: yi = β0 + β1xi + ui, where ui is the error term.
– Homoskedasticity means Var(ui | xi) = σ^2 for all xi. The conditional variance of the error term is constant.
– Graphically: a plot of residuals versus fitted values or versus a predictor shows a roughly uniform band of residuals (no funneling or patterns).
– If variance changes with xi (e.g., residuals fan out as xi increases), that indicates heteroskedasticity.
Why homoskedasticity matters
– OLS coefficients remain unbiased and consistent under heteroskedasticity, but OLS is no longer the best linear unbiased estimator (loses efficiency).
– More importantly for applied work: standard OLS standard errors will be biased, so hypothesis tests, p‑values, and confidence intervals can be incorrect. You can get too many false positives or false negatives unless you correct for heteroskedasticity.
– Thus researchers often report heteroskedasticity‑robust standard errors or use alternative estimation methods when heteroskedasticity is present.
What does heteroskedasticity mean?
– Heteroskedasticity (heteroscedasticity) means Var(ui | xi) is not constant. The dispersion of errors varies with the level of a predictor or across subgroups.
– Example: when modeling income as a function of education, the variability of income may be much greater for higher education levels than for lower ones.
Example (simple, practical)
– Suppose yi is student test score and xi is hours spent studying. If the spread of actual scores around the predicted score is similar for 1 hour, 3 hours, and 10 hours, the errors are homoskedastic.
– If, however, students who study little have widely varying scores (some do well by luck/ability) while high‑study students cluster tightly around high scores, the residual spread increases as study time decreases — that is heteroskedasticity. (Source: Investopedia)
How can you tell if a regression is homoskedastic?
1. Visual check
• Plot residuals vs. fitted values (or vs. an explanatory variable). Look for an even “band” of residuals. Patterns like fanning (cone shape), bowing, or stripes suggest heteroskedasticity.
2. Simple ratio rule (rule of thumb)
• Investopedia mentions a simple heuristic: compare the largest variance to the smallest variance; if the ratio is ≤ 1.5, treat the regression as homoskedastic. This is only a rough rule and should be supplemented by formal testing and graphical inspection. (Source: Investopedia)
3. Formal statistical tests
• Breusch–Pagan test: tests for a systematic relation between squared residuals and the predictors.
• White test: a more general test that allows for nonlinear forms of heteroskedasticity.
• Goldfeld–Quandt test: useful when heteroskedasticity is suspected to vary with the ordering of observations (e.g., increasing variance over time or income).
• Note: tests have size and power limitations; combine tests with diagnostic plots.
Practical steps — diagnosis and remedies (workflow)
1. Fit the OLS model and save residuals.
2. Visual diagnostics:
• Plot residuals vs. fitted values.
• Plot |residuals| or residual^2 vs. fitted values (or vs. suspected variables connected to variance).
3. Run formal tests:
• Breusch–Pagan and White tests (report p‑values).
4. If heteroskedasticity is detected, choose a remedy depending on goals
If primary goal is valid inference (correct SEs, tests, CIs)
• Use heteroskedasticity‑consistent (robust) standard errors (often called “White” or HC0–HC3). These adjust the covariance matrix of the estimated coefficients so inference is valid even if Var(ui) is not constant. This is the most common, straightforward fix in applied work.
• If observations are clustered (e.g., by firm, school, or region), use cluster‑robust standard errors instead.
If primary goal is efficient estimation or prediction
• Weighted least squares (WLS): if you can model Var(ui | xi) = σ^2wi (or proper functional form), run WLS using weights proportional to 1/Var(ui). WLS yields efficient, unbiased coefficients and correct standard errors when the weight model is correct.
• Transform the dependent variable (e.g., log transformation) to stabilize variance when heteroskedasticity is multiplicative (variance proportional to level). Example: for positive skewed outcomes like income, log(y) often reduces heteroskedasticity.
• Add relevant explanatory variables or interaction terms if omitted variables drive the heteroskedasticity pattern.
5. Reassess:
• After applying a remedy, recheck residual plots and run tests again.
Short how-to examples (R and Python)
– R (robust SEs):
• lm.fit <- lm(y ~ x1 + x2, data)
• library(sandwich); library(lmtest)
• coeftest(lm.fit, vcov = vcovHC(lm.fit, type = "HC3"))
– Python (statsmodels, robust SEs):
• import statsmodels.api as sm
• model = sm.OLS(y, X).fit()
• model.get_robustcov_results(cov_type='HC3').summary()
Special considerations
– OLS unbiasedness vs. inference: heteroskedasticity does not bias coefficient point estimates, but biases standard errors if not corrected.
– Grouped/clustered data: heteroskedasticity and within‑group correlation can coexist; use cluster‑robust SEs.
– Time series: heteroskedasticity can be time‑varying (e.g., ARCH/GARCH models) — modeling conditional heteroskedasticity may be appropriate.
– Small samples: some robust SE estimators perform poorly in small samples; HC3 is often recommended over HC0 in small samples.
– Overfitting WLS: misspecifying a variance model for WLS can lead to inefficiency; robust SEs are safer if you aren’t confident in the variance model.
Important
– Always begin with graphical diagnostics. Tests alone can miss patterns or be overly sensitive.
– Reporting: when heteroskedasticity is plausible, report robust standard errors and describe any transformations or weighting used.
– Don’t confuse heteroskedasticity with omitted variable bias — they are different problems (both can be present). Adding relevant predictors can reduce heteroskedasticity if omitted variables cause changing variance.
The bottom line
Homoskedasticity means constant variance of regression errors. It is a key assumption for the usual OLS standard errors to be valid. If the assumption fails (heteroskedasticity), OLS coefficient estimates remain unbiased but standard errors and inference can be misleading. Practical responses include visual diagnostics, formal tests (Breusch–Pagan, White), and remedies such as robust standard errors, transformations, weighted least squares, or richer models. (Primary source: Investopedia —
Further reading
– Investopedia: Homoskedastic
– Wooldridge, J. M., Introductory Econometrics: A Modern Approach — for tests and robust SE discussion.
– Greene, W. H., Econometric Analysis — for advanced treatments of WLS and heteroskedasticity structures.
– Show code and a worked example on a dataset (R or Python).
– Run through a step‑by‑step diagnostics + fix checklist tailored to your data.