data(industry)
mycode <- list(
Consum~quec(Job,0,6),
Pollution~quec(Job,1,11)+quec(Consum,1,6)
)
myfit <- dlsem(mycode,group="Region",exogenous=c("Population","GDP"),
data=industry,uniroot.check=TRUE,log=TRUE)
causalEff(myfit,from="Job",to="Pollution",lag=c(0,5,10,15),cumul=TRUE)
Run the code above in your browser using DataLab