Week 11: Goodness of Fit and Regression Inference
Measures of Variance and Goodness of Fit
Unconditional Variance vs. Error Term Variance
Unconditional Variance (): Measures the total variation in the dependent variable (e.g., ). It is calculated based on the unconditional mean line ().
Formula:
Value in dataset:
Error Term Variance (): Estimates the average variation in the dependent variable that remains unexplained by the regression (based on the regression line ).
Formula:
Value in dataset:
Understanding Variation Components
The regression model decomposes the total variation of the dependent variable into two distinct parts:
Explained Variation (Deterministic Part): Represented by the fitted values . This captures how the explanatory variable (education) explains wages.
Unexplained Variation (Residual Part): Represented by the residuals . This captures the part of wages not explained by education.
The full equation is:
The Sum of Squares Identity
SST (Total Sum of Squares): The total variation in the dependent variable around its mean.
SSR (Regression Sum of Squares): The variation explained by the regression line.
SSE (Sum of Squares of Error): The unexplained variation (sum of squared residuals).
The relationship between these terms is:
Coefficient of Determination ()
Definition: The measures the goodness of fit of the regression. It represents the proportion of variation in the dependent variable explained by the explanatory variable.
Formulas for calculation:
Equivalent form:
Properties of :
Range:
: The regression explains none of the variation.
: The regression explains all of the variation (perfect fit).
Application (Returns to Education):
Interpretation: of the total variation in average wages is explained by education. This suggests very little of the variability in wages is explained by education alone, leading to questions about other factors (Omitted Variables).
Correlation in this dataset:
Inference About Parameters
OLS Estimation Formulas
Slope Estimator:
Intercept Estimator:
Standard Assumptions for OLS Properties
To establish statistical properties, four core assumptions about the error term are required:
Zero Mean: The errors average out to zero.
Constant Variance (Homoskedasticity): The spread of the error term is the same across all levels of X.
Independence: Errors are not correlated with each other.
Exogeneity: The error term is not correlated with the explanatory variable.
BLUE Properties
If the above four assumptions hold, the OLS estimator is BLUE (Best Linear Unbiased Estimator):
Best: Among all linear unbiased estimators, OLS has the smallest variance (most precise). This ensures that the standard errors and are correctly computed.
Linear: The regression is linear with respect to the parameters.
Unbiased: The expected value of the estimators equals the true population parameters: and .
Gaussianity and Central Limit Theorem
Inclusion of the normality assumption for the error term () leads to the result that OLS estimators are normally distributed:
This normality allows for formal hypothesis testing.
Hypothesis Testing Procedures
The Null and Alternative Hypotheses
For a population parameter set to a hypothesized value :
(Two-sided test)
A "statistical significance" test specifically checks if the parameter is different from zero ().
If is rejected: The variable (education) has a statistically significant effect.
If is not rejected: There is insufficient evidence of a linear relationship.
Test Statistic and Decision Rules
t-ratio Test Statistic: Used to test a single restriction on a parameter.
Formula:
Distribution: The test statistic follows the Student-t distribution with degrees of freedom (). The two degrees of freedom are lost by estimating and .
Decision Rule: Reject if |t| > t_{\alpha/2, n-2}.
Example 1: Significance of Education
Hypothesis: vs
Calculations:
Critical Value (, ):
Decision: 14.34 > 1.96. Reject ; education has a statistically significant effect on wages.
Example 2: Testing Scientific Consensus
Context: A study by Andrew Leigh and Chris Ryan (published in Economics of Education Review, 2008) suggests a robust return () to education in Australia.
Hypothesis: vs
Calculations:
Decision: |-3.79| > 1.96. Reject ; our estimate is significantly different from the scientific consensus of .
Confidence Intervals
Constructing Intervals
Confidence intervals (CI) provide a range of plausible values for the true population parameters based on the estimator properties.
Formula for Slope:
Formula for Intercept:
Interpretation: The interval will contain the true parameter value in of repeated samples.
Wage Data Results (95% CI)
Slope (Education):
Intercept:
Because neither interval includes zero, both parameters are statistically significant at the level.
Prediction in Regression Analysis
Objectives of Economic Forecasting
Conditional Mean Prediction: Predicting the average outcome for a given X-value (e.g., average wage for everyone with 15.5 years of education). This is a "point prediction."
Density Prediction (Non-Examinable): Providing the complete probability distribution of future individual outcomes.
Conditional Mean Prediction Calculations
Estimating the population regression function at a specific value :
Example (15.5 years of education):
Result: The expected log-hourly wage is
Example (Expected gain from college): Comparing 15 years vs. 12 years of education.
Interpretation: A college graduate increases expected wage by relative to high school graduates (percentage interpretation because wages are in logs).
Confidence Intervals for Conditional Mean Forecast
The CI for the mean reflects uncertainty in estimating the regression line because different samples produce different lines.
Standard Error ():
For :
95% CI Range:
This interval is very narrow, indicating precise conditional mean forecasting.
Prediction Interval (PI) for an Individual Outcome
A predictive interval provides the range for an individual's future wage. It is wider than a confidence interval because it reflects two sources of error:
Uncertainty in estimating the regression line (sampling uncertainty).
Natural variation of individuals around that line (error term variance).
Standard Error ():
For : The SE is approximately
95% PI Range:
This interval tells where an individual's wage is likely to fall for a given education level with probability.
Summary Comparison (at 15.5 years education)
Confidence Interval (Mean): (Contains the true expected value).
Prediction Interval (Individual): (Contains the true individual predicted log-wage).