Generating parameters from vector of estimates

Hi.

I have a model with quite a large number of parameters to declare for stoch_simul. I was wondering if it’s possible to for example automatically generate parameter initialisation values in a mod file doing stoch_simul from the posterior mode vector without manually copying and pasting from excel or matlab into the mod file? Or if you have other tips on faster and more reliable ways to unpack a vector of estimates into parameter declarations in the mod file, you’re welcome.

Thanks a lot.

This is feasible but you have to do a little programming. Separate your work in 2 MOD files: the first one with the estimation, the second one for the stoch_simul. At the end of the first file, save your posterior mode in a MAT file. At the beginning of the 2nd file, load the previous MAT file and assign the values to the parameters (in M_.params). If you use a different set of parameters between the 2 models, you’ll have to pay attention to the mapping between the 2 sets.

Best,

Ok, thanks a lot.

I think I ended up doing exactly this following Wouter Den Haan’s suggestion in his slides for looping over stoch_simul for multiple parameter vectors.