To run Dynare codes

Dear all,

I am a new user of Dynare and Matlab. I have installed Dynare v3 under Matlab directory. I just want to know how to input “rbc.mod” to Matlab. I cannot run any examples.

I need your help.

Regards,
Tebby

Hi Tebby,

You should first set Matlab’s path to your Dynarev3 directory: In Matlab, click File->Set Path then choose your Dynare v3 directory from the folder tree, click on Add with subfolders, then Save and Close. If you are working on a network computer, you might have to do this every time you open up Matlab, which is pretty irritating for me since I run 10 jobs simultaneously on different servers and I have to log off at least once a week. Does anybody know a way to get around this by the way?

Now type rbc.mod in Command Window.

PS Dynare User Guide is your friend! :wink:

I beg to differ, the *.mod file can’t be entered in Matlab Command Window. You need to use Matlab editor or any other ASCII editor. Make sure that the file name is correct after you have saved it.

Instead of saving the path, you can look at Matlab
addpath()
and
the default starting function startup.m

You will find details in Matlab documentation

Best

Michel

[quote=“MichelJuillard”]I beg to differ, the *.mod file can’t be entered in Matlab Command Window. You need to use Matlab editor or any other ASCII editor. Make sure that the file name is correct after you have saved it.

Michel[/quote]

Oh, I thought Tebby meant they could not RUN the .mod file. But if they need to EDIT the file, of course Michel is right. I should have been more clear when I said “type rbc.mod”, I didn’t mean “type the whole mod file in command window”, sorry about that.

And, thanks for the tip Michel!

Maybe you’re right. If the original question was about telling Matlab to run Dynare on rbc.mod the syntax is

dynare rbc

No need to add the .mod extension

Best

Michel