Panel Data Analysis
INTRO Panel Data is where you observe behavior of entities across time. Allows to control for unobservable variables that change over time but not entity Allows to control for unobservable variables across entities xtset entity time
xtline fatalityrate, (ov)
Fixed Effect Models
xi: reg fatalityrate sb_useage i.fips i.year predict yhat separate yhat, by(fips) separate yhat, by(year) twoway connected yhat1-yhat56 sb_useage|| lfit fatalityrate sb_useage, clwidth(thick) clcolor(black) twoway connected yhat1983-yhat1997 sb_useage|| lfit fatalityrate sb_useage, clwidth(thick) clcolor(black) Eq 2 Dummy Variables
Eq 1 n entity-specific intercepts areg fatalityrate sb_useage, absorb(state) areg fatalityrate sb_useage year2…year10, absorb(state)
xtset fips year xtreg fatalityrate sb_useage, fe Eq 1 n entity-specific intercepts
xtreg options fe: fixed effects Explores relationship between estimations and outcomes within an entity. Assumes each entity has own characteristics that may influence yhat to control for. re: random effects Variation across entities is assumed to be random and uncorrelated with the independent variables included in the model be: between effects pa: population-average