I´m a new matlab and dynare user

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.

I´m a new matlab and dynare user

Postby cagocu » Mon Jan 13, 2014 2:20 pm

Hello Friends,

I´m a new matlab and dynare user, I have beed reading some tutorial about that programs work but i can not undertand how i can manage the file, for example: if i have a model file, how i can open? I have to create a folder in the same directory where dynare is? please, if you have some document that helpme about manage a file, I would be very grateful.
cagocu
 
Posts: 3
Joined: Mon Jan 13, 2014 2:06 pm

Re: I´m a new matlab and dynare user

Postby Daniel Bendel » Mon Jan 13, 2014 3:37 pm

It is pretty simple:
1. Just create a folder, where you save your mod file, say model.mod
2. Then add the path where you save dynare to your workplace, just by typing (in fact you have to write YOUR path, where YOU have saved dynare): addpath c:\dynare\4.4.0\matlab
3. Open the model file, just by typing in the command window: dynare model.mod
Germany, Cologne
Daniel Bendel
 
Posts: 134
Joined: Tue Nov 15, 2011 1:06 pm
Location: Cologne, Germany

Re: I´m a new matlab and dynare user

Postby jpfeifer » Mon Jan 13, 2014 4:17 pm

mod-files are simple text files. They can be opened with any editor. Typically, people open these files with the Matlab editor. The instruction above describes the procedure for Matlab.
------------
Johannes Pfeifer
University of Cologne
https://sites.google.com/site/pfeiferecon/
jpfeifer
 
Posts: 6940
Joined: Sun Feb 21, 2010 4:02 pm
Location: Cologne, Germany

Re: I´m a new matlab and dynare user

Postby cagocu » Tue Jan 14, 2014 12:35 am

Hello Friends

Thanks so much for your help. I have one questions, I have to create a folder to save model file in the same place where dynare is save? for example, the path where i save dyanare is C:\dynare y créate in dynare a folder like this C:\dynare\models?
cagocu
 
Posts: 3
Joined: Mon Jan 13, 2014 2:06 pm

Re: I´m a new matlab and dynare user

Postby Daniel Bendel » Tue Jan 14, 2014 8:40 am

No, you don't have to do this. Just save the folder where you want, but I think it is better not to save it where you saved dynare in order to keep things clean...
Germany, Cologne
Daniel Bendel
 
Posts: 134
Joined: Tue Nov 15, 2011 1:06 pm
Location: Cologne, Germany

Re: I´m a new matlab and dynare user

Postby cagocu » Sat Jan 25, 2014 11:10 pm

Hello Friends,

I want to know if someone writes in the module where he has to declare the variables (in the file .mod) something like that:

var
c_t $c$ % % total consumption
ch_t $c^{h}$ % % domestic consumption

which means the front of the column before the comment? for example $c$. I know that the expresión after %% its a comment.
cagocu
 
Posts: 3
Joined: Mon Jan 13, 2014 2:06 pm

Re: I´m a new matlab and dynare user

Postby jpfeifer » Mon Jan 27, 2014 7:36 am

Yes, the code
Code: Select all
ch_t $c^{h}$ % % domestic consumption

does the following. The first entry defines the variable ch_t for use in Dynare. The second entry in the $ $-signs is a LaTeX declaration. It tells Dynare to use these LaTeX-Codes for the variable ch_t when using commands like
Code: Select all
write_latex_dynamic_model;

as documented in the manual. This second part is optional. If no LaTeX definition is present, Dynare will just use the Dynare variable name.
In your case, you could for example just use
Code: Select all
var
c_t % total consumption
ch_t % domestic consumption
------------
Johannes Pfeifer
University of Cologne
https://sites.google.com/site/pfeiferecon/
jpfeifer
 
Posts: 6940
Joined: Sun Feb 21, 2010 4:02 pm
Location: Cologne, Germany


Return to Dynare help

Who is online

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