Macro-processor language and loops

Dear all,

I am having a question concerning macro-processing language and loops in Dynare 4.4.3. I am using the macro-processing language to define new macro-processor variables, where I can have conditional statements on thereafter in the mod file. My question is whether I can have loops on the macro-processor variable values, outside of the mod file, in a separate m file. So for example, for different values of these macro-processor variables, run the dynare *.mod file.

Thank you for your help in advance.


No, that is not possible, but you can use Matlab variables outside of the mod-file and pass them to the mod-file to set preprocessor variables. That should to the trick. This can be done with the -D switch in the command line. See [Loop over certain antizipation horizons)

Dear Johannes,

Thank you so much. It works perfectly.

Kind regards,