by adamshap » Fri Aug 11, 2006 7:42 pm
Thank you for the example Michel. However, I think this example is not doing exactly what I am trying to do.
What I am trying to do is simulate a couple variables for which there exist no data. In other words, use the model to back-out "hidden" variables that exist in the model, but not in any data source.
To do this, I am taking the following approach -- which does not seem to be working for some reason.
1) Estimate the model to obtain the parameters and exogenous shocks. The exogenous shocks are saved in the oo_ file.
2) I then simulate model, in a deterministic context, with the shocks saved from the estimation in the oo_ file. I save them in a file called datafile.mat. I have been doing this with the shocks(shocks_file = datafile.mat) command. For example:
shocks(shocks_file = datafile);
var pdot_;
periods 1;
values 0;
var rff_;
periods 1;
values 0;
var ygap_;
periods 1;
values 0;
end;
For those variables for which I have data, the simulation should give me back a time series that looks like the data that I put into the estimation process. It is not doing so. Instead, much of the simulated time-sereis I am getting back (i.e. what I get when I use the rplot command at the end of the simulation) looks quite different from the data. Other times it resembles the data, but is not quite there.
Perhaps you could help explain why the approach I have taken is not working correctly in Dynare.
In order to better simulate the hidden variables, I was wondering if I could put the data directly into the simulation, just like I put the shocks into the simulation -- this would be the static simulation. This would not involve solving the model for policy functions as is shown in your example, but rather use the model to map out the variables for which there is no data. Is there a command to simulate the model with some of the endogenous variables updated each period with the actual data?