Shocks: Estimated standard deviations

I am new with Dynare. I have already read the Johanes’s guide. However, I am not sure whether or not I have correctly specified my observation equations. I have used the logged data from the Smets/Wouters paper which I have divided by 100. My model equations are non-linear. Dut to the fact that some variables like gdp have a trend, my observation equations read as dy=logy-logy(-1)+ctrend+eps, where ctrend is the net-growth rate and eps is an iid error term. When I run the simulations, the estimated standard deviations of the shocks are a bit to large. Maybe someone can help me.sim1.mod (2.6 KB)

The data file is missing. Also, you should use a steady_state_model-block

Thanks for your help. Please find attached the data file. These are the Smets/Wouters data. I only use dy, dc and dinve as observation equations. My problem is that I want to estimate standard deviations for a tfp, a government expenditure and a mark-up shock. The calibrated values are SigmaZ = 0.0045; Sigmat = 0.0014 and Sigmag=0.0052. If I shut off the mark-up and government shock, I get a reasonable estimate for SigmaZ. However, if I allow for all three shocks, my estimates are somewhat strange. data.mod (18.9 KB)

  1. Please upload a working version of both the data file used and the mod-file in a zip-file. Currently, I get
dynare_estimation_init:: The steady state at the initial parameters cannot be computed.
  1. Please describe what you mean with “strange results”?

I hop that will work now. Many thanks for your help. (9.0 KB)

Dynare does not support txt-files for data, so this cannot be the right data file (29.9 KB)

I am very sorry. Attached the data as and excel file. I have now used the data by sm. Again, my estimates for the standard deviations of the technology shock and government shock seems to be strange. Maybe the problem are the obs equations. Thanks again for the help.

I ran mode_compute=9 and got

Fval obtained by the minimization routine (minus the posterior/likelihood)): 220.401990

   prior mean     mode    s.d. prior pstdev

RhoZ   0.850   0.9985     NaN beta  0.1000 
ctrend   0.400   0.4005     NaN norm  0.1000 

standard deviation of shocks
   prior mean     mode    s.d. prior pstdev

e1     0.100   0.0102     NaN invg  2.0000 

The parameter estimates seem not totally crazy, but the prior seems strange. I needed to set prior_trunc=0, because your prior does not allow low estimated standard deviations otherwise.

That is exactly the problem. When I estimate the model only with the tfp shock using dy=(logy-logy(-1))100+trend with logdifferenced gdp100 froms meets wouters it works well.

prior mean post. mean 90% HPD interval prior pstdev

RhoZ 0.850 0.9567 0.9233 0.9878 beta 0.1000
ctrend 0.400 0.4092 0.3695 0.4543 norm 0.1000

standard deviation of shocks
prior mean post. mean 90% HPD interval prior pstdev

e1 0.001 0.0067 0.0059 0.0074 invg 2.0000

Instead, if I additionally want to estimate a government spending shock, the post. mean of the standard deviation of e3 is strange, isnt it? Here I use logdiff*100 from investment, also from sm.

prior mean post. mean 90% HPD interval prior pstdev

RhoZ 0.850 0.9450 0.9229 0.9697 beta 0.1000
Rhog 0.850 0.9903 0.9855 0.9950 beta 0.1000
ctrend 0.400 0.4028 0.3659 0.4479 norm 0.1000

standard deviation of shocks
prior mean post. mean 90% HPD interval prior pstdev

e1 0.001 0.0047 0.0040 0.0053 invg 2.0000
e3 0.001 0.1833 0.1621 0.2089 invg 2.0000

The observation equations seems to be correctly specified. Do you have a clue what the reason for this results could be? Your help is pretty much appreciated.

Please provide a zip-file with the specification that gives these strange results.

Thanks a lot for your help. The zipf file contains two mod.files. The first mod-file considers the estimation of the technology shock,the second the estimation of both, a technology and a government spending shock. The estimation of the post. mean of e3 (which is the standard deviation of the government shock) is 18.41 but I expect a value around 0.4-0.6 like for the technologty shock. Maybe I miss something. Nevertheless, I would be very happy for helping me with this issue. (31.1 KB)

I would have expected the process to be


Thanks for your answer. That is correct. However, even if I use the specification g2=Rhog*g2(-1)+e3, I have still the problem that everything but the standard deviation is well estimated.

prior mean post. mean 90% HPD interval prior pstdev

RhoZ 0.850 0.9440 0.9199 0.9677 beta 0.1000
Rhog 0.850 0.9904 0.9847 0.9948 beta 0.1000
ctrend 0.400 0.4023 0.3659 0.4409 norm 0.1000

standard deviation of shocks
prior mean post. mean 90% HPD interval prior pstdev

e1 0.100 0.4717 0.4004 0.5375 invg 2.0000
e3 0.100 5.1656 4.5473 5.8632 invg 2.0000

Is this a normalization problem?

That’s hard to tell. You should investigate the economics, e.g. via the IRFs. A 5 percent standard deviation is not outrageous. With a G/Y-share of 0.2 we are talking about 1 percent of GDP in terms of size.