Dynare external function

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.

Dynare external function

Postby anupmulay1 » Mon Feb 01, 2016 9:15 pm

I am trying to solve a NK model with capital using Dynare. I am getting an error which is as follows;

ERROR: Bean_2004_AER.mod: line 18, cols 1-7: To use an external function (psi) within the model block, you must first declare it via the external_function() statement.

Can anyone please help me with this? I am attaching my .mod file here.

Thank you.

Anup
Attachments
Bean_2004_AER.mod
(3.36 KiB) Downloaded 289 times
anupmulay1
 
Posts: 11
Joined: Mon Feb 01, 2016 8:46 pm

Re: Dynare external function

Postby jpfeifer » Tue Feb 02, 2016 7:57 am

You are using a variable named psi, but it is not declared as a variable in the var statement.
------------
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: Dynare external function

Postby anupmulay1 » Tue Feb 02, 2016 10:53 am

Thank you Prof. Pfeifer. I have fixed that like you said. I am now facing more of an economics issue. I have 13 equations but 14 endogenous variables, and I do not know which equation I am missing in the system. Is this something you could advise me about? It would be a great help. I am attaching the mod file, if you would be willing to take a look.
Attachments
Bean_2004_AER.mod
(3.35 KiB) Downloaded 285 times
anupmulay1
 
Posts: 11
Joined: Mon Feb 01, 2016 8:46 pm

Re: Dynare external function

Postby jpfeifer » Thu Feb 04, 2016 12:26 pm

Sorry, but I cannot replicate the paper for you. You have to find out yourself which elements of the paper need to go into the mod-file.
------------
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: Dynare external function

Postby hscbsc » Fri Aug 12, 2016 4:00 pm

Hi,

This is unrelated to problem above, however related to general use of external_function.
While using external_function I assume dynare numerically calculated first and second order derivatives. However, if I am using third order approximation, dynare doesn't calculate third order derivatives and throws an error.

Is there a workaround/solution to this ?

Thanks.
hscbsc
 
Posts: 25
Joined: Mon Jan 11, 2016 5:35 am

Re: Dynare external function

Postby jpfeifer » Fri Aug 12, 2016 4:51 pm

Not yet, it is on our to-do list: https://github.com/DynareTeam/dynare/issues/300
------------
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 User Guide

Who is online

Users browsing this forum: No registered users and 0 guests