Is it possible to reuse preprocessing output?



I am new to dynare. I have a model with 200 variables and many more model-local variables (about 2000). Preprocessing this on my windows pc with 8gb ram takes close to 2 hours. Is it possible to store the output of the preprocessing step and use it in the next run of the model?

Thank you


That depends on what you mean with

What exactly is the experiment you have in mind? Preprocessing is required whenever you change the structure of the model.


I am running stoch_simul and am using a Matlab file to get the steady state. To start execution, I am running eval([‘dynare dynamicModel.mod’]) in Matlab. When I say “next run”, I mean running this eval statement again.

If I do not change the structure of the model or the values of the parameters, does the preprocessor automatically understand that it can use the output from the previous run or do I have to ask it to use the last output with some command?

Thank you


That does not really answer my question. Most of the times, there is no purpose to rerun Dynare on the mod-file. It is often sufficient to call the particular Matlab functions of Dynare again. That even allows changing parameters. Examples of this are estimation via moment or IRF matching.


I see. I was not aware of this. I am trying to generate IRFs to the steady state of my model. Which Matlab file should I run the next time once preprocessing is done? Does it have a specific name?


You still did not answer the question what you are changing between different runs of the model. Without knowing that, it is impossible to tell.


Sorry, I am only changing a few parameter values between different runs of the model.

Can I change that in some file generated by the preprocessor and run that file instead of rerunning the preprocessor? Which is that file?

Thanks a lot!


In that case, you run the model once and after that only call the main m-file created by the preprocessor. After that, you can use set_param_value to change parameters and can call functions like stoch_simul directly. See e.g.