Download presentation
Presentation is loading. Please wait.
1
Econometric Analysis of Panel Data
William Greene Department of Economics Stern School of Business
2
Regression Extensions
Time Varying Fixed Effects Measurement Error Spatial Autoregression and Autocorrelation (Baltagi 10.5)
3
Time Varying Effects Models
Time Varying Fixed Effects: Additive yit = β’xit + ai(t) + εit yit = β’xit + ai + ct + εit ai(t) = ai + ct, t=1,…,T Two way fixed effects model Now standard in fixed effects modeling.
4
Evidence of technical change
LSDV least squares with fixed effects .... LHS=YIT Mean = Standard deviation = No. of observations = DegFreedom Mean square Regression Sum of Squares = Residual Sum of Squares = Total Sum of Squares = Standard error of e = Root MSE Fit R-squared = R-bar squared Estd. Autocorrelation of e(i,t) = Panel:Groups Empty , Valid data Smallest 6, Largest Average group size in panel Variances Effects a(i) Residuals e(i,t) Std.Devs Rho squared: Residual variation due to ai Within groups variation in YIT D+02 R squared based on within group variation Between group variation in YIT D+03 | Standard Prob % Confidence YIT| Coefficient Error z |z|>Z* Interval X1| *** X2| *** X3| X4| *** T| Base = 1993 1994 | *** 1995 | *** 1996 | *** 1997 | *** 1998 | *** Evidence of technical change
5
Time Varying Fixed Effects
911 Rescue
6
Need for Clarification
7
Time Varying Fixed Effects
8
A Partial Fixed Effects Model
9
Time Varying Effects Models
Time Varying Fixed Effects: Additive Polynomial yit = β’xit + ai(t) + εit yit = β’xit + ai0 + ai1t + ai2t2+ εit Let Wi = [1,t,t2]Tx3 Ai = stack of Wi with 0s inserted Use OLS, Frisch and Waugh. Extend “within” estimator. Note Ai’Aj = 0 for all i j. See Cornwell, Schmidt, Sickles (1990) (Frontiers literature.)
10
Cornwell Schmidt Sickles
13
calc;list;r2=1-(1482-col(x)-3*247)*sst/((n-1)*var(yit))$
[CALC] R = F[2*247, *247] = ( )/(2*247) / (( )/(1482 – 4 – 3*247)) = 6.45 Wald = 6.45*494 = Critical chi squared for 494 DF =
14
Time Varying Effects Models
Random Effects yit = β’xit + εit + ai(t) or yit = β’xit + εit + uig(t,) A heteroscedastic random effects model Stochastic frontiers literature – Battese-Coelli (1992)
16
Munnell State Production Model
17
No Effects
18
Quadratic Fixed Effects
Correct DF: (48)=666 Multiply standard errors by sqr(810/666) = 1.103
19
Time Varying Effects Models
Time Varying Fixed Effects: Multiplicative yit = β’xit + ai(t) + εit yit = β’xit + it + εit Not estimable. Needs a normalization. 1 = 1. An EM iteration: (Chen (2015).)
20
EM Algorithm (Chen (2015))
21
Measurement Error
22
General Conclusions About Measurement Error
In the presence of individual effects, inconsistency is in unknown directions With panel data, different transformations of the data (first differences, group mean deviations) estimate different functions of the parameters – possible method of moments estimators Model may be estimable by minimum distance or GMM With panel data, lagged values may provide suitable instruments for IV estimation. Various applications listed in Baltagi (pp ).
23
Application: A Twins Study
24
Wage Equation
26
Spatial Autocorrelation
Thanks to Luc Anselin, Ag. U. of Ill.
27
Spatially Autocorrelated Data
Per Capita Income in Monroe County, NY Thanks Arthur J. Lembo Jr., Geography, Cornell.
28
Hypothesis of Spatial Autocorrelation
Thanks to Luc Anselin, Ag. U. of Ill.
29
Testing for Spatial Autocorrelation
W = Spatial Weight Matrix. Think “Spatial Distance Matrix.” Wii = 0.
30
Modeling Spatial Autocorrelation
31
Spatial Autoregression
32
Generalized Regression
Potentially very large N – GPS data on agriculture plots Estimation of . There is no natural residual based estimator Complicated covariance structure – no simple transformations
33
Spatial Autocorrelation in Regression
34
Panel Data Application: Spatial Autocorrelation
36
Spatial Autocorrelation in a Panel
37
Spatial Autocorrelation in a Sample Selection Model
Flores-Lagunes, A. and Schnier, K., “Sample Selection and Spatial Dependence,” Journal of Applied Econometrics, 27, 2, 2012, pp Alaska Department of Fish and Game. Pacific cod fishing eastern Bering Sea – grid of locations Observation = ‘catch per unit effort’ in grid square Data reported only if 4+ similar vessels fish in the region sample = 320 observations with 207 reported full data
38
Spatial Autocorrelation in a Sample Selection Model
LHS is catch per unit effort = CPUE Site characteristics: MaxDepth, MinDepth, Biomass Fleet characteristics: Catcher vessel (CV = 0/1) Hook and line (HAL = 0/1) Nonpelagic trawl gear (NPT = 0/1) Large (at least 125 feet) (Large = 0/1)
39
Spatial Autocorrelation in a Sample Selection Model
40
Spatial Autocorrelation in a Sample Selection Model
41
Spatial Weights
42
Appendix: Miscellaneous
43
Ordinary Least Squares
Standard results for OLS in a GR model Consistent Unbiased Inefficient Variance does (we expect) converge to zero;
44
Estimating the Variance for OLS
45
White Estimator for OLS
46
Generalized Least Squares
47
Maximum Likelihood
48
Conclusion Het. in Effects
Choose robust OLS or simple FGLS with moments based variances. Note the advantage of panel data – individual specific variances As usual, the payoff is a function of Variance of the variances The extent to which variances are correlated with regressors. MLE and specific models for variances probably don’t pay off much unless the model(s) for the variances is (are) of specific interest.
49
Generalized Regression
50
OLS Estimation
51
Feasible GLS
52
GLS Estimation
53
Heteroscedasticity Naturally expected in microeconomic data, less so in macroeconomic Model Platforms Fixed Effects Random Effects Estimation OLS with (or without) robust covariance matrices GLS and FGLS Maximum Likelihood
54
Dear Professor Greene, I have to apply multiplicative heteroscedastic models, that I studied in your book, to the analysis of trade data. Since I have not found any Matlab implementations, I am starting to write the method from scratch. I was wondering if you are aware of reliable implementations in Matlab or any other language, which I can use as a reference.
55
Baltagi and Griffin’s Gasoline Data
World Gasoline Demand Data, 18 OECD Countries, 19 years Variables in the file are COUNTRY = name of country YEAR = year, LGASPCAR = log of consumption per car LINCOMEP = log of per capita income LRPMG = log of real price of gasoline LCARPCAP = log of per capita number of cars See Baltagi (2001, p. 24) for analysis of these data. The article on which the analysis is based is Baltagi, B. and Griffin, J., "Gasoline Demand in the OECD: An Application of Pooling and Testing Procedures," European Economic Review, 22, 1983, pp The data were downloaded from the website for Baltagi's text.
56
Heteroscedastic Gasoline Data
57
Does Teaching Load Affect Faculty Size. Becker, W. , Greene, W
Does Teaching Load Affect Faculty Size? Becker, W., Greene, W., Seigfried, J. Do Undergraduate Majors or PhD Students Affect Faculty Size? American Economist 56(1): Becker, Jr., W.E., W.H. Greene & J.J. Siegfried. 2011 Mundlak form of Random Effects
58
Random Effects Regressions
59
Modeling the Scedastic Function
60
Two Step Estimation
61
Heteroscedasticity in the RE Model
62
LSDV Residuals
63
Evidence of Country Specific Heteroscedasticity
64
Heteroscedasticity in the FE Model
Ordinary Least Squares Within groups estimation as usual. Standard treatment – this is just a (large) linear regression model. White estimator
65
In order to test robustness two versions of the fixed effects model were run. The first is Ordinary Least Squares, and the second is heteroscedasticity and auto-correlation robust (HAC) standard errors in order to check for heteroscedasticity and autocorrelation. [Only one version of the model was computed. There was no “check.”]
66
Narrower Assumptions
67
Heteroscedasticity in Gasoline Data
| Least Squares with Group Dummy Variables | | LHS=LGASPCAR Mean = | | Fit R-squared = | | Adjusted R-squared = | Least Squares - Within |Variable | Coefficient | Standard Error |t-ratio |P[|T|>t] | Mean of X| LINCOMEP LRPMG LCARPCAP White Estimator LINCOMEP LRPMG LCARPCAP White Estimator using Grouping LINCOMEP LRPMG LCARPCAP
68
Estimating the Variance Components: Baltagi
Invoking Mazodier and Trognon (1978) and Baltagi and Griffin (1988).
69
Estimating the Variance Components: Hsiao
So, who’s right? Hsiao. This is no longer in Baltagi. Invoking Mazodier and Trognon (1978) and Baltagi and Griffin (1988).
70
Maximum Likelihood
71
OLS and PCSE +--------------------------------------------------+
| Groupwise Regression Models | | Pooled OLS residual variance (SS/nT) | | Test statistics for homoscedasticity: | | Deg.Fr. = 17 C*(.95) = C*(.99) = | | Lagrange multiplier statistic = | | Wald statistic = | | Likelihood ratio statistic = | | Log-likelihood function = | |Variable | Coefficient | Standard Error |b/St.Er.|P[|Z|>z] | Constant LINCOMEP LRPMG LCARPCAP | OLS with Panel Corrected Covariance Matrix | Constant LINCOMEP LRPMG LCARPCAP
72
FGLS +--------------------------------------------------+
| Groupwise Regression Models | | Pooled OLS residual variance (SS/nT) | | Log-likelihood function = | |Variable | Coefficient | Standard Error |b/St.Er.|P[|Z|>z] | Constant LINCOMEP LRPMG LCARPCAP | Test statistics against the correlation | | Deg.Fr. = 153 C*(.95) = C*(.99) = | | Likelihood ratio statistic = | Constant LINCOMEP LRPMG LCARPCAP
73
Autocorrelation Source? Already present in RE model – equicorrelated.
Models: Autoregressive: εi,t = ρεi,t-1 + vit – how to interpret Unrestricted: (Already considered) Estimation requires an estimate of ρ
74
FGLS – Fixed Effects
75
FGLS – Random Effects
76
Microeconomic Data - Wages
| Least Squares with Group Dummy Variables | | LHS=LWAGE Mean = | | Model size Parameters = | | Degrees of freedom = | | Estd. Autocorrelation of e(i,t) | |Variable | Coefficient | Standard Error |b/St.Er.|P[|Z|>z] | OCC SMSA MS EXP EXPSQ D
77
Macroeconomic Data – Baltagi/Griffin Gasoline Market
| Least Squares with Group Dummy Variables | | LHS=LGASPCAR Mean = | | Estd. Autocorrelation of e(i,t) | |Variable | Coefficient | Standard Error |t-ratio |P[|T|>t] | LINCOMEP LRPMG LCARPCAP
78
Aggregation Test
79
Baltagi and Griffin’s Gasoline Data
World Gasoline Demand Data, 18 OECD Countries, 19 years Variables in the file are COUNTRY = name of country YEAR = year, LGASPCAR = log of consumption per car LINCOMEP = log of per capita income LRPMG = log of real price of gasoline LCARPCAP = log of per capita number of cars See Baltagi (2001, p. 24) for analysis of these data. The article on which the analysis is based is Baltagi, B. and Griffin, J., "Gasoline Demand in the OECD: An Application of Pooling and Testing Procedures," European Economic Review, 22, 1983, pp The data were downloaded from the website for Baltagi's text.
80
A Test Against Aggregation
Log Likelihood from restricted model = Free parameters in and Σ are (19)/2 = 175. Log Likelihood from model with separate country dummy variables = Free parameters in and Σ are = 192 Chi-squared[17]=2( )=442.07 Critical value= Homogeneity hypothesis is rejected a fortiori.
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.