Question about permanent shock


I am new to Dynare and I have a model with a permanent shock that is supposed to stay forever. So after finding the steady state I wrote this:

var switchh;
periods 1:50;
values 1;

So “switchh” should go from 0 to 1 and then stay there forever. However when I simulate this for 50 periods, in period 51 it goes back to 0 (and also all other variables go back to their initial steady state values. Can this be ignored (since it is after the end of the specified period) or does it affect the whole simulation?

Best and thanks for any help!


This sounds as if your are missing an endval-block.

Thanks Prof. Pfeifer for your reply!
So basically, all I wanna do is find the steady state for switch=0 and then simulate the convergence to the new steady for switch=1.

Do you mean that I have to impose the “old” steady state values via initval and the “new” ones via endval?


See DSGE_mod/Solow_SS_transition.mod at master · JohannesPfeifer/DSGE_mod · GitHub