I study a transition experiment in Chapter 11 of Ljungqvist and Sargent's book. I found Dynare codes from the accompanying programs with "Practice Dynare". It is about a permanent increase in the government spending. But when I attempted to extend it to the stochastic environment, I found something weird to me. I attach my revised codes here:
----------------------------------------------------------------------------------------------------
var c k A;
varexo taui tauc tauk g epis;
parameters bet gam del alpha rho sigma;
bet=.95;
gam=2;
del=.2;
alpha=.33;
rho=0.95;
sigma=0.007;
model;
k=A*k(-1)^alpha+(1-del)*k(-1)-c-g;
c^(-gam)= bet*(c(+1)^(-gam))*((1+tauc(-1))/(1+tauc))*((1-taui)*(1-del)/(1-taui(-1))+
((1-tauk)/(1-taui(-1)))*alpha*A*k(-1)^(alpha-1));
log(A)=rho*log(A(-1))+epis;
end;
initval;
k=1.5;
c=0.6;
A=1;
g = 0.2;
tauc = 0;
taui = 0;
tauk = 0;
end;
steady;
shocks;
var epis;
stderr sigma;
var g;
periods 1:9 10:100;
values 0.2 0.4;
end;
stoch_simul(periods=100,drop=0);
k0=oo_.endo_simul(2,:);
c0=oo_.endo_simul(1,:);
figure
subplot(1,2,1)
plot(k0)
title('k')
subplot(1,2,2)
plot(c0)
title('c')
---------------------------------------------------------------------------------------------------
The idea is that instead of fixed productivity, I want to the transition path with uncertainty. I can generate a graph but it is quite different from the one in the deterministic environment (see Figure 6 in the handout "Practice Dynare"): first, the consumption even increases in the beginning and second, both variables have quite different levels compared to the deterministic case. So I wonder if I can really use Dynare to accomplish my objective. If so, then what is wrong with my codes?
Thanks a lot!