Errors on Smets-Wouters MoDEL

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.

Errors on Smets-Wouters MoDEL

Postby sunrain » Tue Dec 09, 2008 4:02 am

Dear All,

As a beginner, I'm trying to operate linear Smets-Wouter model with dynare 4.01 on matlab 2007a; I got following messages:
dynare sw

Configuring Dynare ...
[mex] Generalized QZ.
[mex] Sylvester equation solution.
[mex] Kronecker products.
[mex] Sparse kronecker products.

Starting Dynare ...
Starting preprocessing of the model file ...
ERROR: sw.mod:12.0-1: syntax error, unexpected NAME

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

I checked my code detailed, but could not find any unexpected name. Could anyone provide helps? Thanks!

See attached code

Lukas
Attachments
sw.mod
(2.13 KiB) Downloaded 877 times
sunrain
 
Posts: 19
Joined: Tue Dec 11, 2007 8:46 am

Re: Errors on Smets-Wouters MoDEL

Postby p.gelain » Thu Dec 11, 2008 4:32 pm

Hi

you simply forgot to put the SEMICOLON at the end of the line 11 (invy=0.22)

Paolo
p.gelain
 
Posts: 61
Joined: Wed Jul 11, 2007 9:13 pm
Location: Norges Bank

Re: Errors on Smets-Wouters MoDEL

Postby sunrain » Fri Dec 12, 2008 3:50 am

Paolo,
Thanks. But after I added the semicolon in line11, I operated it on Matalab 2007a with dyanre 4.02, It still told
dynare sw

Configuring Dynare ...
[mex] Generalized QZ.
[mex] Sylvester equation solution.
[mex] Kronecker products.
[mex] Sparse kronecker products.

Starting Dynare ...
Starting preprocessing of the model file ...
ERROR: sw.mod:47.103: syntax error, unexpected NAME, expecting INT_NUMBER or MINUS or PLUS

??? Error using ==> dynare at 96
DYNARE: preprocessing failed
sunrain
 
Posts: 19
Joined: Tue Dec 11, 2007 8:46 am

Re: Errors on Smets-Wouters MoDEL

Postby p.gelain » Fri Dec 12, 2008 10:39 am

Hi

you have written p(t-1) instead of p(-1).

Paolo
p.gelain
 
Posts: 61
Joined: Wed Jul 11, 2007 9:13 pm
Location: Norges Bank

Re: Errors on Smets-Wouters MoDEL

Postby sunrain » Thu Dec 25, 2008 3:22 am

Dear Paolo,

Thanks! I got the results.

Another question, could you tell me how to match the observable data with the variable in the linear model?

When I conducted estimation in dynare with same model, I always got the wrong information, saying that an unexpexted parenthesis in the regarding .m file.

Thanks again.

Lukas
sunrain
 
Posts: 19
Joined: Tue Dec 11, 2007 8:46 am

Re: Errors on Smets-Wouters MoDEL

Postby sunrain » Fri Dec 26, 2008 2:38 am

dynare bsw

Configuring Dynare ...
[mex] Generalized QZ.
[mex] Sylvester equation solution.
[mex] Kronecker products.
[mex] Sparse kronecker products.

Starting Dynare ...
Starting preprocessing of the model file ...
23 equation(s) found
Processing derivation ...
Processing Order 1... done
Processing Order 2... done
Processing outputs ...
Preprocessing completed.
Starting Matlab computing ...

??? Error: File: bsw.m Line: 313 Column: 1
Unbalanced or unexpected parenthesis or bracket.

"Error in ==> dynare at 102
evalin('base',fname) ;
var_list_=[];
dynare_estimation(var_list_);
);
save('bsw_results.mat', 'oo_');
diary off"

When I deleted the parenthesis in bsw.m, and conducted bsw.m
it said:
STEADY: numerical initial values incompatible with the following equations
2 4

??? Error using ==> dynare_solve at 82
exiting ...

Error in ==> steady_ at 69
[oo_.steady_state,check] = dynare_solve([M_.fname '_static'],...

Error in ==> steady at 52
steady_;

Error in ==> bsw at 247
steady;

what's the problem?

Thanks,

Lukas
sunrain
 
Posts: 19
Joined: Tue Dec 11, 2007 8:46 am

Re: Errors on Smets-Wouters MoDEL

Postby martin » Mon Dec 13, 2010 2:35 pm

Hey guys

I get kind of the same troubles with my own model (the mod file is attached)... I obtain the following error message:

ERROR: aghionhowitt.mod:22.0: syntax error, unexpected INT_NUMBER
Starting Dynare (version 4.1.3).
Starting preprocessing of the model file ...

error: DYNARE: preprocessing failed
error: called from:
error: /Applications/Dynare/4.1.3/matlab/dynare.m at line 126, column 1

I don't really understand the "unexpected INT_NUMBER" comment. Regarding what I've seen up here, it seems that some variable is not well-defined or should get a time lag, but I really can't find where!

Thanks for your help

Martin

PS: the program is not really finished, I just want to get rid of those syntax errors for the moment...
Attachments
aghionhowitt.mod
(666 Bytes) Downloaded 259 times
martin
 
Posts: 3
Joined: Mon Nov 29, 2010 2:40 pm

Re: Errors on Smets-Wouters MoDEL

Postby jpfeifer » Mon Dec 13, 2010 5:55 pm

The line
Code: Select all
1/(c)^epsilon = mu*(1+gamma)*(zz)^gamma;

in the endval block is not a correct assignment for c. Solve the equation for c.
------------
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 7 guests