Correlogram / ACF plot: Visual inspection of autocorrelation function.
7.2.4 Remedies
Newey‑West standard errors (heteroskedasticity‑ and autocorrelation‑consistent).
Feasible Generalized Least Squares (FGLS) – e.g., Cochrane‑Orcutt or Prais‑Winsten for AR(1) errors.
Include lagged dependent variables or other dynamics in the model.
7.3 Instrumental Variables (IV) / Two‑Stage Least Squares (2SLS)
7.3.1 The Problem of Endogeneity
Endogeneity occurs when an independent variable is correlated with the error term:
Corr(Xⱼ, u) ≠ 0
Common causes:
Omitted variables – the omitted variable is correlated with Xⱼ.
Measurement error – Xⱼ is measured with error.
Simultaneity (reverse causality) – Y influences Xⱼ.
7.3.2 The Instrumental Variables Solution
An instrument Z is a variable that:
Relevance: Corr(Z, X) ≠ 0 (Z is correlated with the endogenous X).
Exogeneity: Corr(Z, u) = 0 (Z is uncorrelated with the error).
The IV estimator is:
β̂IV = Cov(Z, Y) / Cov(Z, X)
7.3.3 Two‑Stage Least Squares (2SLS)
Stage 1: Regress X on all instruments and exogenous variables. Obtain fitted values X̂.
Stage 2: Regress Y on X̂ and exogenous variables. The coefficient on X̂ is the 2SLS estimate.
Important: The number of instruments must be at least the number of endogenous variables.
If you have more instruments than endogenous variables, you can test for overidentifying restrictions (Sargan / Hansen J test).
7.4 MORISTAT Implementation
Currently, the MORISTAT web console does not include built‑in commands for:
Robust standard errors (White / Newey‑West)
Breusch‑Pagan, White, Durbin‑Watson tests
IV / 2SLS estimation
However, you can manually compute some diagnostics using the residuals from REGRESS. For example, after a regression, you can examine residuals for patterns.
Manual diagnostic example:
MORISTAT> LOAD hetero_data.csv
MORISTAT> REGRESS Y ~ X
MORISTAT> DIAG (shows residuals, skewness, kurtosis)
MORISTAT> PREDICT (gives fitted values and residuals)
You can then plot residuals vs fitted values using external software to check for heteroskedasticity.
7.5 Practice Exercises
Exercise 7.1: Detecting Heteroskedasticity
You estimate the model: Wage = β₀ + β₁ × Education + β₂ × Experience + u.
After estimating, you plot the residuals against Education and see a fan‑shaped pattern (variance increases with Education).
What does this pattern suggest?
What are the consequences for your regression results?
What remedy would you suggest?
Solution:
Suggests heteroskedasticity.
Consequences: OLS still unbiased but inefficient; standard errors are biased (usually too small).
Remedy: Use robust standard errors or transform the dependent variable (e.g., log(Wage)).
Exercise 7.2: Serial Correlation in Time Series
You have quarterly data on GDP growth and estimate the model: GDP_growth = β₀ + β₁ × InterestRate + u.
The Durbin‑Watson statistic is 0.45.
What does a DW statistic close to 0 indicate?
What is the consequence for OLS?
How could you fix this problem?
Solution:
DW close to 0 indicates strong positive autocorrelation (ρ̂ ≈ 1).
Consequence: OLS is inefficient, and standard errors are biased (often understated).
Fix: Use Newey‑West standard errors or estimate an AR(1) model (e.g., Cochrane‑Orcutt).
Exercise 7.3: Instrumental Variables
You want to estimate the effect of education on wages, but education is endogenous because ability is unobserved and correlated with education. You have a potential instrument: distance to the nearest college.
Explain why distance to college might be a good instrument for education.
What assumptions must hold for distance to be a valid instrument?
If you have only one instrument for one endogenous variable, can you test the validity of the instrument?
Solution:
Distance to college is likely correlated with education (closer → more likely to attend college) – relevance.
It must be uncorrelated with the error term (i.e., not directly affecting wages except through education) – exogeneity.
With one instrument for one endogenous variable, the model is just‑identified; you cannot test the exogeneity assumption (overidentifying restrictions test requires more instruments than endogenous variables).
Exercise 7.4: 2SLS in Practice
You have data on education, wages, and two instruments: distance and parent_education. Describe the steps to estimate the effect of education on wages using 2SLS.
Solution:
Stage 1: Regress Education on distance, parent_education, and any other exogenous variables. Obtain fitted values Education̂.
Stage 2: Regress Wage on Education̂ (and other exogenous variables).
The coefficient on Education̂ is the 2SLS estimate of the causal effect of education on wages.
Since you have 2 instruments for 1 endogenous variable, you can test overidentifying restrictions (Sargan test) to check instrument validity.
7.6 Key Terms
HeteroskedasticityHomoskedasticityBreusch‑Pagan TestWhite TestRobust Standard ErrorsWeighted Least Squares (WLS)Serial CorrelationAutocorrelationDurbin‑Watson TestNewey‑West Standard ErrorsEndogeneityInstrumental Variable (IV)RelevanceExogeneityTwo‑Stage Least Squares (2SLS)Overidentifying Restrictions
7.7 Further Reading
Wooldridge, J.M. (2020). Introductory Econometrics: A Modern Approach, Chapters 8 (Heteroskedasticity), 12 (Serial Correlation), 15 (Instrumental Variables).