Two models (different parameters) and one .mod file

This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location where you will have to reset your password.
Forum rules
This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location (https://forum.dynare.org) where you will have to reset your password.

Two models (different parameters) and one .mod file

Postby petros_varth » Thu Apr 24, 2014 9:53 pm

Hi All,

I use a standard New Keynesian model, i would like to run the model with and without (flexible model) nominal rigidities. Then, i would like to use specific variables, i.e. output, of the flexible model as a target variable in the rigid model. Any ideas how to do this while running only a mod. file?

Best,

P.
petros_varth
 
Posts: 45
Joined: Wed Sep 30, 2009 5:35 pm

Re: Two models (different parameters) and one .mod file

Postby HoutanBastani » Mon Apr 28, 2014 10:29 am

You can invoke dynare twice from a matlab script. By using the macroprocessing language in your mod file and passing macro values on the dynare command line with the -D option you can do what you want. See the manual for the macroprocessing language and dynare invocation options.
Best,
Houtan
HoutanBastani
 
Posts: 197
Joined: Fri Jan 22, 2010 4:11 pm
Location: Paris, France

Re: Two models (different parameters) and one .mod file

Postby petros_varth » Thu May 01, 2014 11:26 am

Thanks a lot.

I tried this and it works fine.

P.
petros_varth
 
Posts: 45
Joined: Wed Sep 30, 2009 5:35 pm

Re: Two models (different parameters) and one .mod file

Postby ahnulxy » Fri May 02, 2014 10:03 pm

Actually, there are other ways out.
If the model if not so complex, you can actually calculate the flexible output and get a closed form for the flexible output. And then you can define this flexible output as another variable in the same mod file without using two mod file.

If you have capital in the model, usually, flexible output does not has a closed form solution.
ahnulxy
 
Posts: 43
Joined: Thu May 10, 2012 7:24 am


Return to Dynare help

Who is online

Users browsing this forum: Google [Bot] and 6 guests