I would like to reproduce a Poisson Vector Autoregression Model by Brandt and Sandler with stan (they used BUGS).
Here is the respective code from Ryan Batt (thanks!):
VAR_p_cov.stan (1000 Bytes)
Essentially, I would like to insert a hierarchical layer, where the dependent variables are poisson distributed and the latent lambdas are modeled by the VAR process.
I have problems getting the latent lambdas into a matrix form. Forgive me if this is trivial; I am new to stan and any help is greatly appreciated.