Strange Error when using steady_state() in dynare 4.4.0

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.

Strange Error when using steady_state() in dynare 4.4.0

Postby Daniel Bendel » Wed Jan 08, 2014 6:56 pm

Hey all,

I get a strange error when I'm using the steady_state() command instead of using the # code to correctly vary steady state values during estimation as suggested by Prof Pfeifer on page 38 in https://sites.google.com/site/pfeiferec ... edirects=0

For example:
I have government debt in my model. The steady state value should be 68% of GDP's steady state value: Bss = SBss*Yss; (SBss = 0.68)
The model code runs fine without any error, if I write for every Bss when needed:
SBss*steady_state(Y)
But if I write:
steady_state(B)
dynare says it can't find the steady state since matrix is close to singular and every following estimation breaks down with exactly the same error!

This is really strange???

Does anyone knows why this error happens??

Daniel
Germany, Cologne
Daniel Bendel
 
Posts: 134
Joined: Tue Nov 15, 2011 1:06 pm
Location: Cologne, Germany

Re: Strange Error when using steady_state() in dynare 4.4.0

Postby jpfeifer » Thu Jan 09, 2014 6:19 am

Please provide me with 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: Strange Error when using steady_state() in dynare 4.4.0

Postby Daniel Bendel » Thu Jan 09, 2014 9:51 am

At first: thanks for your interest.
here is my code:

it is equation 16: there I want to use steady_state(B)
and also equation 22: there I want to use steady_state(Bstar)

but both produce the above described error.

(the rar-file contains three files: one is the dynare mod-file, the two other are necessary to calculate the steady state)
Last edited by Daniel Bendel on Fri Jan 10, 2014 7:58 pm, edited 1 time in total.
Germany, Cologne
Daniel Bendel
 
Posts: 134
Joined: Tue Nov 15, 2011 1:06 pm
Location: Cologne, Germany

Re: Strange Error when using steady_state() in dynare 4.4.0

Postby Daniel Bendel » Thu Jan 09, 2014 9:55 am

the above file works. But as I said when replacing in mentioned lines the code with the steady_state command it does work only with an error message.
Germany, Cologne
Daniel Bendel
 
Posts: 134
Joined: Tue Nov 15, 2011 1:06 pm
Location: Cologne, Germany

Re: Strange Error when using steady_state() in dynare 4.4.0

Postby jpfeifer » Fri Jan 10, 2014 9:58 am

Model_diagnostics indicates a collinearity problem. This seems to be the source of the error. Due to this problem, Dynare seems to have problems finding the steady state for B and Bstar.
------------
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: Strange Error when using steady_state() in dynare 4.4.0

Postby Daniel Bendel » Fri Jan 10, 2014 11:23 am

Thank you for pointing out where the mistake is hidden. Okay so far, the problematic equation is the monetary rule defined by a simple taylor rule. But I need the taylor equation to pin down my inflation of the nominal price index.
So why is dynare complaining about this?
And in what relation does the taylor equation stands with determining B and Bstar?
Germany, Cologne
Daniel Bendel
 
Posts: 134
Joined: Tue Nov 15, 2011 1:06 pm
Location: Cologne, Germany

Re: Strange Error when using steady_state() in dynare 4.4.0

Postby Daniel Bendel » Fri Jan 10, 2014 3:36 pm

As I steped deeper in this issue, the error becomes stranger and stranger:

1. I solved for the steady state with my matlab code.
2. These steady state solutions are exactly the solutions which dynare caluculates, in the case when I do NOT use the steady_state command but instead Bss and Bstarss.
3. That's why (I think) the mod-file works.
4. BUT: when I use the steady_state command the dynare intern solver runs only with the warning of singularity and also finds a steady state, which is exactly the same as my solution with the matlab program I have written, up to the steady state values for Bss and Tss (the steady state for the transfers of the government), which differ from the steady state solution of my matlab m-file.

So I think: there must be a problem of identifying the steady state values of B and T. Perhaps the solution is not unique?
Or is this a bug in the 4.4.0 version?
Germany, Cologne
Daniel Bendel
 
Posts: 134
Joined: Tue Nov 15, 2011 1:06 pm
Location: Cologne, Germany

Re: Strange Error when using steady_state() in dynare 4.4.0

Postby jpfeifer » Fri Jan 10, 2014 5:32 pm

Sounds as if your steady state is not unique as bonds and lump sum taxes seem to be perfect substitutes. Are you sure you correctly killed Ricardian Equivalence?
------------
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: Strange Error when using steady_state() in dynare 4.4.0

Postby Daniel Bendel » Fri Jan 10, 2014 6:42 pm

mmh, that is a good point. Can you give me a hint how to do that or where I can look it up?

(I thought with pinning down the steady state of Bss by saying that it has to be 68% of GDP steady state value I have already solved this issue, or havn't I ?)
Germany, Cologne
Daniel Bendel
 
Posts: 134
Joined: Tue Nov 15, 2011 1:06 pm
Location: Cologne, Germany

Re: Strange Error when using steady_state() in dynare 4.4.0

Postby Daniel Bendel » Fri Jan 10, 2014 7:46 pm

beside this, I found my error. but neverless it would be also great to hear an answer to the previously made question (if you have time).
The error arises because I set as the initial value for the marginal costs (nuu-1)/nuu instead of using that MC = 1/A*alphaa^(-alphaa)*(1-alphaa)^(-(1-alphaa))*RKss^(alphaa)*Wss^(1-alphaa).
In fact in the steady state both values have to be the same, but I think the error arises as dynare find it difficult to use both price setting equations to find the steady state for the marginal cost as both are quite similar in the steady state. (???, I don't kown if this is really the right answer, just a guess...)
In addition the model diagnostic (when I use steady_state(B)) now clearly points out the issue with the ricadian equivalence, as it says:
model_diagnostic: the Jacobian of the static model is singular
there is 1 colinear relationships between the variables and the equations
Colinear variables:
T
B
Colinear equations
17

The presence of a singularity problem typically indicates that there is one
redundant equation entered in the model block, while another non-redundant equation
is missing. The problem often derives from Walras Law.


When I instead use 0.68*steady_state(Y), then the model diagnostic says:
model_diagnostic: the Jacobian of the static model is singular
there is 1 colinear relationships between the variables and the equations
Colinear variables:
C
N
I
W
K
Y
G
T
B
RB
MC
Px
Qm
Qd
Qx
Pm
Pd
PI
Z
E
EX
IM
Colinear equations
17

The presence of a singularity problem typically indicates that there is one
redundant equation entered in the model block, while another non-redundant equation
is missing. The problem often derives from Walras Law.

(IS THIS NORMAL???)
Nevertheless for estimation to aviod the ricadian equivalence problem which causes the "Matrix is close to singular" problem, one has to use 0.68*steady_state(Y) instead of steady_state(B).
Germany, Cologne
Daniel Bendel
 
Posts: 134
Joined: Tue Nov 15, 2011 1:06 pm
Location: Cologne, Germany

Re: Strange Error when using steady_state() in dynare 4.4.0

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

I am not sure to understand the full model, but the intertemporal budget constraint gives you a link between output, debt, and transfers. Typically, with Ricardian equivalence only the present value of taxation is pinned down. Basically, for every additional unit of debt B in steady state, transfers in every period must amount to the interest on this perpetual bond. That way, interest is paid in every period and debt is never repaid. This shows you why the amount of debt and transfers cannot be determined endogenously (unless the transfers are distortionary to ensure an interior maximum). In contrast, fixing debt to a share of output automatically also fixes transfers.
------------
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: No registered users and 6 guests