- I am adding in an AR() structure into my brms multilevel model. It increases run time by around 50%. Any way to get around this? My data is non-nested and structured as firms across time, within countries. I have around 280,000 data points across 24 years and 24 countries. The panel is not balanced so some years are missing for most firms. This is the code I added for the AR() structure.
autocor = cor_ar(form = ~ year | firm_identifier , p = 1)
- Also note that it is not accounting for the country structure of the data --unsure how best to do that. Nor is it accounting for the fact that the panel is not balanced. Suggestions would be appreciated.
And just to add, in case this is relevant, this multilevel model is estimating fixed effects and group-level random effects at the following levels:
year:country.…which may be slowing down the AR() process even more?