Error in Matlab

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.

Error in Matlab

Postby audrey » Sun Mar 07, 2010 4:43 pm

Dear All,

I'm trying to simulate this simple deterministic model using dynare, but I keep getting this error message:

>> dynare model1

Configuring Dynare ...
[mex] Generalized QZ.
[mex] Sylvester equation solution.
[mex] Kronecker products.
[mex] Sparse kronecker products.
[mex] Bytecode evaluation.
[mex] k-order perturbation solver.
[mex] k-order solution simulation.

Starting Dynare (version 4.1.0).
Starting preprocessing of the model file ...
ERROR: model1.mod:31.7: character unrecognized by lexer

??? Error using ==> dynare at 126
DYNARE: preprocessing failed

Does any one know what is wrong in my model file?

Thanks a lot!

Best,
Audrey
Attachments
model1.mod
(1.32 KiB) Downloaded 85 times
audrey
 
Posts: 3
Joined: Fri Mar 05, 2010 4:43 am

Re: Error in Matlab

Postby AssiaEzzeroug » Sun Mar 07, 2010 6:03 pm

Hi,

Mainly I noted the following syntax errors. You need to remove the symbol backslash that appears at each line of your mod-file. Each equation inside the block model should end by a semicolon. Try to check the definition of the variable k; basically it can't be declared both as exogenous and endogenous variable.

Best
AssiaEzzeroug
 
Posts: 83
Joined: Tue Nov 24, 2009 3:48 pm

Re: Error in Matlab

Postby audrey » Tue Mar 09, 2010 12:09 pm

Hi,

Thanks a lot for your reply, I realized that my problem is with the TextEdit in Mac.
May I know which editor should I use if I try to create a mod file in mac?

Thanks a lot in advance.

Best,
Audrey
audrey
 
Posts: 3
Joined: Fri Mar 05, 2010 4:43 am

Re: Error in Matlab

Postby SébastienVillemot » Wed Mar 10, 2010 9:53 am

Hi

I'm not a Mac user, but a good choice is to use the internal editor of MATLAB, which you invoke by typing "edit" at the prompt.

Otherwise the best editor, but not the most user friendly, is GNU Emacs (there must be a Mac package around).

Best
Sébastien Villemot
Economist at OFCE – Sciences Po
SébastienVillemot
 
Posts: 706
Joined: Fri Dec 07, 2007 2:29 pm
Location: Paris, France

Re: Error in Matlab

Postby audrey » Mon Mar 15, 2010 1:59 pm

Hi,

Thanks a lot! The built-in editor in Matlab is great, there is no backslashes in my mod file anymore.

Best,
Audrey
audrey
 
Posts: 3
Joined: Fri Mar 05, 2010 4:43 am


Return to Dynare help

Who is online

Users browsing this forum: No registered users and 8 guests