I’m working with a model that is log-linearized. When estimating the model, I use the data expressed as percentages. I also treat my shocks in the model as %. For example, I treat
stderr epsilon_zetac, inv_gamma_pdf, 0.200, inf;
as a 0.2 % shock.
Which of the following measurement equations, let me say, for output, is correct?
- dy_obs = 100*ln(mu_z) + y_hat - y_hat(-1) + mu_zhat;
- dy_obs = 100ln(mu_z) + 100(y_hat - y_hat(-1) + mu_zhat);
The first one? Because my shocks are already scaled in percent, so there is no need to multiply the model variables by 100. Am I right?
This is hard to tell without knowing what is what in your equation. As your equation does not seem to be mean 0, you have to account for multiplying the data by 100 when dealing with the mean. However, you do not want to tell Dynare that the model deviations from mean correspond to 100 times the data deviations from mean, because both have been multiplied by 100 (in the model due to the adjusted shock standard deviation). So the first one looks better than the second if you have already multiplied your growth rates by 100.
Here are the definitions of variables:
dy_obs = 100 * Delta ln (GDP)
y_hat = Y_t-Y_ss/Y_ss
mu_z = Steady state quarterly gross growth rate, i.e. 1.006, so that 100ln(mu_z) = 0.6
mu_zhat = unit-root technology shock, i.e. mu_zhat = rhomu_zhat(-1) + epsilon_muz
Ok, then the first equation is consistent with what I wrote and should be correct.
Problems not yet over… When running the estimation using the data in percentages, I get a very huge number for Initial value of the log posterior (or likelihood): i.e. 10-digit number. Is it ok?
The estimation procedure then proceeds normally, but just before the results of the posterior mode should be displayed, I get the well-known error message (I use mode_compute=6):
Error using chol
Matrix must be positive definite.
Error in gmhmaxlik (line 197)
dd = transpose(chol(CovJump));
Error in dynare_estimation_1 (line 437)
[xparam1,PostVar,Scale,PostMean] = …
Error in dynare_estimation (line 89)
Error in brezm_brezrf (line 953)
Error in dynare (line 180)
No that is not OK and suggests that there is still a problem. Please provide the files.
I would recommend staying with the version that is not multiplied by 100. The model you are looking at has very complicated observation equations where it is not straightforward to scale.
Additionally, you selectively multiplied some observed variables by 100, while you kept other unscaled. That is wrong, because these unscaled variables are supposed to be affected by the same shocks that you now scaled by 100.