Page 1 of 1

simulation gives non-smooth transition

PostPosted: Thu Feb 17, 2011 3:47 pm
by rumecos
I use deterministic case, and simulation gives me non-smooth transition to a new steady state. In particular, variables jump in the first period, and then transit to the new steady state. I believe that this is because of some error term used by dynare. Because when my model was simple, by using own code (not dynare) I was getting similar jump as dynare, and after decreasing error term in value function iterations I was able to eliminate this jump, i.e. transition was smooth. But now my model is too complicated and It may take much longer to do it by myself.

Is there any way to change error term used in dynare?

Thanks in advance.

Re: simulation gives non-smooth transition

PostPosted: Tue Feb 22, 2011 12:36 pm
by SébastienVillemot
Please explain what you mean by "error term".

When solving for deterministic simulation, Dynare simply solves the full stacked non-linear system, as entered by the user.

Re: simulation gives non-smooth transition

PostPosted: Tue Feb 22, 2011 9:03 pm
by rumecos
Dear Sébastien,
My .mod file is attached.



I was able to achieve smooth transition by decreasing tolerance level (for convergence) in value function iterations. Now I don't know what to do with dynare.
Thank you for your interest.

Re: simulation gives non-smooth transition

PostPosted: Wed Feb 23, 2011 9:21 am
by SébastienVillemot
You can try to lower the tolerance level of Dynare deterministic simulator by changing the value of "options_.dynatol". The default value is 0.00001.

Re: simulation gives non-smooth transition

PostPosted: Wed Feb 23, 2011 2:23 pm
by rumecos
tried, but it does not improve the results, stil getting jump in the first period...

Re: simulation gives non-smooth transition

PostPosted: Wed Feb 23, 2011 3:11 pm
by jpfeifer
Hi,
could the reason be that there is no transition process for your exogenous variable F? If you look into oo_.exo_simul, F jumps from 0.1 in period 1 to 0.8 in period 2.
As
Code: Select all
Cm=Km^alpha*Lm^(1-alpha)+(1-i)*F;

, if F jumps, so does CM and so do all the other variables.

Re: simulation gives non-smooth transition

PostPosted: Wed Feb 23, 2011 3:17 pm
by rumecos
Yes, F should jump in period 1 and remain high forever as this is a permanent shock. But endogenous variables have to make smooth transitions as they do after the first period.

Re: simulation gives non-smooth transition

PostPosted: Wed Feb 23, 2011 7:45 pm
by jpfeifer
But are you sure that your model features sufficient transmission mechanisms that must make the transition for all variables absolutely smooth? If you look at the equation for Cm you see the following: the only way for Cm to have a smooth transition without a jump in response to a jump in F is to have counteracting jumps in either Km or Lm or in both. Are you sure that this is the case so that it must be a computational issue?

Re: simulation gives non-smooth transition

PostPosted: Wed Feb 23, 2011 8:16 pm
by rumecos
In equation for Cm I have variable "i" which gets zero value in the steady states and have counteracting jump during the transition. You can observe this after period one. I believe this makes transition of Cm smooth.
Also if you are right, then all my variables should jump to the new steady state at once as F. But what is happening, they jump in period one and then gradually converge to the new steady state.

Re: simulation gives non-smooth transition

PostPosted: Wed Feb 23, 2011 8:45 pm
by jpfeifer
You may be right. But my argument is somewhat different. In period 1, a shock to F suddenly hits the system. Of course, there are counteracting movements in other variables, for example in i. But they may be not strong enough to prevent a jump.
If my conjecture is correct, it is not necessarily the case that the sytem directly jumps to the new steady state. This is due to the endogenous dynamics, i.e. leads and lags. If the transmission of the shock is not extremely smooth (e.g. depending on the model: habits in consumption and leisure, investment adjustment costs, interest rate smoothing), there will be a one time jump in the first period due to the jump in F. The system jumps to the new saddlepath. But this is not the new steady state. Rather, the system then slowly transitions along the saddlepath to the new steady state.

Re: simulation gives non-smooth transition

PostPosted: Thu Feb 24, 2011 1:04 pm
by rumecos
I could agree with you if my own code with value function iterations did not deliver smooth transition.