Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

ERF Training Workshop Panel Data 4

177 views

Published on

Raimundo Soto - Catholic University of Chile

ERF Training on Advanced Panel Data Techniques Applied to Economic Modelling

29 -31 October, 2018
Cairo, Egypt

Published in: Government & Nonprofit
  • Be the first to comment

  • Be the first to like this

ERF Training Workshop Panel Data 4

  1. 1. ERF Training Workshop Panel Data 4 Raimundo Soto Instituto de EconomΓ­a, PUC-Chile
  2. 2. FIRST-DIFFERENCES ESTIMATOR β€’ Another alternative to tackle the heterogeneity problem of 𝑦𝑖𝑑 = 𝛼𝑖 + 𝛽π‘₯𝑖𝑑 + πœ€π‘–π‘‘ consists in first- differencing the model 𝑦𝑖𝑑 βˆ’ π‘¦π‘–π‘‘βˆ’1 = 𝛼𝑖 + 𝛽π‘₯𝑖𝑑 + πœ€π‘–π‘‘ βˆ’ 𝛼𝑖 + 𝛽π‘₯π‘–π‘‘βˆ’1 + πœ€π‘–π‘‘βˆ’1 βˆ†π‘¦π‘–π‘‘= π›½βˆ†π‘₯𝑖𝑑 + βˆ†πœ€π‘–π‘‘ β€’ Hence, the first-difference estimator is simply 𝛽 𝐹𝐷 = βˆ†π‘₯π‘–π‘‘β€²βˆ†π‘₯𝑖𝑑 βˆ’1βˆ†π‘₯π‘–π‘‘β€²βˆ†π‘¦π‘–π‘‘ 2
  3. 3. FIRST-DIFFERENCES ESTIMATOR β€’ This estimator is consistent if 𝐸[π‘₯𝑖𝑑 πœ€π‘–π‘‘] = 0 but slightly less efficient than the within estimator – Notice: the restriction is 𝐸 π‘₯𝑖𝑑 πœ€π‘–π‘‘ and the exogeneity of π‘₯𝑖𝑑 is not needed as is the case in the within estimator (e.g., it allows for correlation between π‘₯𝑖𝑑 y πœ€π‘–π‘‘βˆ’2). β€’ Notice that the residual βˆ†πœ€π‘–π‘‘ is autocorrelated even if πœ€π‘–π‘‘ is not. Thus t-statistics are distorted β€’ All information on non-time varying variables is lost. β€’ First observation of each individual is lost 3
  4. 4. FIRST-DIFFERENCES ESTIMATOR RESULTS 4 _cons .0337766 .0045505 7.42 0.000 .0248557 .0426975 D1. -.0998219 .1910678 -0.52 0.601 -.4743976 .2747537 l_popt D1. -.0134668 .0029968 -4.49 0.000 -.0193419 -.0075917 l_infl2 D1. -.2939159 .0468332 -6.28 0.000 -.3857292 -.2021026 l_realgdp D.l_money Coef. Std. Err. t P>|t| [95% Conf. Interval] Total 162.369352 5064 .032063458 Root MSE = .17805 Adj R-squared = 0.0113 Residual 160.435782 5061 .031700411 R-squared = 0.0119 Model 1.93357008 3 .644523359 Prob > F = 0.0000 F( 3, 5061) = 20.33 Source SS df MS Number of obs = 5065
  5. 5. 5 * p<0.1, ** p<0.05, *** p<0.01 t statistics in parentheses Observations 5436 5436 5436 5436 5065 (39.10) (-31.67) (5.14) (-18.82) (7.42) Constant 3.315*** -7.845*** 2.450*** -4.160*** 0.0338*** (-0.52) D.Population -0.0998 (-4.49) D.Inflation -0.0135*** (-6.28) D.Real GDP -0.294*** (0.24) (2.56) (0.30) (2.62) Population 0.00144 0.0732** 0.00875 0.0564*** (-20.94) (-5.92) (-6.24) (-7.92) Inflation -0.165*** -0.0281*** -0.406*** -0.0403*** (-2.36) (25.09) (-0.37) (21.47) Real GDP -0.00867** 0.385*** -0.00630 0.258*** Pooled Within Between Random FirstDif (1) (2) (3) (4) (5)
  6. 6. FIT β€’ The R2 statistics is valid to undertake comparisons between the pooled model pooled and the fixed effects model. β€’ Using R2 statistics to undertake comparisons between the fixed effects model and the random effects model is invalid, because the individual effects 𝛼𝑖 are random variables in FE but are part of the error term in the RE model. 6
  7. 7. HETEROSKEDASTICITY TESTS β€’ We would like to test whether 𝜎2 (i) = 𝜎2 , for all 𝑖 = 1, … , 𝑁 β€’ This only makes sense in the fixed effects model 7 Prob>chi2 = 0.0000 chi2 (163) = 3.3e+05 H0: sigma(i)^2 = sigma^2 for all i in fixed effect regression model Modified Wald test for groupwise heteroskedasticity . xttest3 It is heteroskedastic
  8. 8. UNBALANCED PANELS β€’ When dealing with the estimation of the model 𝑦𝑖𝑑 = 𝛼𝑖 + 𝛽π‘₯𝑖𝑑 + πœ€π‘–π‘‘ We tacitly assumed that we observed data for 𝑖 = 1, … 𝑁 at each instant of time 𝑑 = 1, … , 𝑇 β€’ What if there are missing data? – It depends on how the data got lost 8
  9. 9. UNBALANCED PANELS β€’ From a mechanic point of view, the within estimator is not sensitive to missing data, since as long as you can compute: 𝑆 𝑀 π‘₯π‘₯ = 𝑖=1 𝑁 𝑑=1 𝑇 π‘₯𝑖𝑑 βˆ’ π‘₯𝑖 β€² π‘₯𝑖𝑑 βˆ’ π‘₯𝑖 𝑆 𝑀 π‘₯𝑦 = 𝑖=1 𝑁 𝑑=1 𝑇 π‘₯𝑖𝑑 βˆ’ π‘₯𝑖 β€² 𝑦𝑖𝑑 βˆ’ 𝑦𝑖 You can obtain: 𝛽 𝑀 = 𝑆 𝑀 π‘₯𝑦 𝑆 𝑀 π‘₯π‘₯ 9
  10. 10. UNBALANCED PANELS β€’ Computing the estimator is not the main issue, but why data is missing. β€’ Let 𝑠𝑖𝑑 indicate if one observation exists or is missing. That is 𝑠𝑖𝑑 takes value 1 if the observation exists and 0 otherwise. β€’ Let us remove the mean of each individual using the available data; 𝑦𝑖𝑑 = 𝑦𝑖𝑑 βˆ’ 1 𝑇 𝑖 π‘Ÿ=1 𝑇 π‘ π‘–π‘Ÿ π‘¦π‘–π‘Ÿ π‘₯𝑖𝑑 = π‘₯𝑖𝑑 βˆ’ 1 𝑇 𝑖 π‘Ÿ=1 𝑇 π‘ π‘–π‘Ÿ π‘₯π‘–π‘Ÿ 𝑇𝑖 = 𝑑=1 𝑇 𝑠𝑖𝑑 10
  11. 11. UNBALANCED PANELS β€’ The FE estimator is 𝛽 𝑀 = (𝑁𝑇)βˆ’1 π‘₯𝑖𝑑´ π‘₯𝑖𝑑 βˆ’1 (𝑁𝑇)βˆ’1 π‘₯𝑖𝑑´ 𝑦𝑖𝑑 = π‘βˆ’1 𝑖=1 𝑁 𝑑=1 𝑇 𝑠𝑖𝑑 π‘₯𝑖𝑑´ π‘₯𝑖𝑑 βˆ’1 π‘βˆ’1 𝑖=1 𝑁 𝑑=1 𝑇 𝑠𝑖𝑑 π‘₯𝑖𝑑´ 𝑦𝑖𝑑 = 𝛽 + π‘βˆ’1 𝑖=1 𝑁 𝑑=1 𝑇 𝑠𝑖𝑑 π‘₯𝑖𝑑´ π‘₯𝑖𝑑 βˆ’1 π‘βˆ’1 𝑖=1 𝑁 𝑑=1 𝑇 𝑠𝑖𝑑 π‘₯π‘–π‘‘Β΄πœ€π‘–π‘‘ 11
  12. 12. UNBALANCED PANELS β€’ The FE estimator will be consistent if and only if π‘π‘™π‘–π‘š π‘βˆ’1 𝑖=1 𝑁 𝑑=1 𝑇 𝑠𝑖𝑑 π‘₯π‘–π‘‘Β΄πœ€π‘–π‘‘ = 0 β€’ It requires no correlation between π‘₯𝑖𝑑 and πœ€π‘–π‘‘ β€’ It requires no correlation between 𝑠𝑖𝑑 and πœ€π‘–π‘‘. That is: – The nature of heterogeneity must be uncorrelated to choice – Feedback must be absent for choice to be exogenous β€’ In summary, E(𝛼) must not depend on 𝑠𝑖𝑑 12

Γ—