Page 1 of 1

A first-time user really needing help

PostPosted: Mon Feb 27, 2012 10:56 pm
by marmaxguzman
Dear Dynare community:

I'm trying to be a first-time Dynare user, but unfortunately I'm being unable to run any of the sample examples. My Matlab version is 7.11.0, and my Dynare version is 4.2.4. As stated in the user guide, my first order to Matlab is

addpath /Applications/Dynare/4.2.4/matlab

Later, I try to run an example, like for instance the example1.mod attached file, by writing

dynare example1

The program indicates there is an error in line 97. Line 97 is the "error" line of the following section


d = dir(fname);
if length(d) == 0
error(['DYNARE: can''t open ' fname])
end

As suggested in one of the previous discussions on the forum, I comment that line and go on. When I do that, I get another error in line 115. Line 115 is the "error" line of the following section:

[status, result] = system(command);
disp(result)
if status
% Should not use "error(result)" since message will be truncated if too long
error('DYNARE: preprocessing failed')
end


I comment that line and go on, and then I get another error at line 121:

evalin('base',fname) ;

I have no idea about how to continue trying, and considering I'm writing a DSGE model, I'm certain I would extremely benefit from using Dynare (not only now but also in a long term).

I would really appreciate your help. I promise to offer my help as many times as possible when I become a solid user.

Thanks very much,
Martin

Re: A first-time user really needing help

PostPosted: Tue Feb 28, 2012 9:59 am
by jpfeifer
Have you set your Matlab working directory to the folder where the mod-file is located? It seems Dynare can't find the file.
Moreover, you can try adding the Dynare path to the Matlab path by going to File -> Set Path -> Add with subfolders

Re: A first-time user really needing help

PostPosted: Tue Feb 28, 2012 3:57 pm
by marmaxguzman
Thanks for your answer. I've done that, but still doesn't work. Didn't this problem happen to anyone else?

Re: A first-time user really needing help

PostPosted: Tue Feb 28, 2012 4:59 pm
by jpfeifer
Inside Matlab type
Code: Select all
which example1.mod

Is the answer identical to your working directory?

Re: A first-time user really needing help

PostPosted: Tue Feb 28, 2012 6:12 pm
by marmaxguzman
The problem has been solved. Thanks so much to jpfeifer.