Monte Carlo experiment

Dear Johannes, dear all,

I am evaluating a forecasting performance of a small open model and its closed variant. As a part of my analysis, I would like to conduct the Monte Carlo experiment as in Rubaszek and Kolasa (2018), but I am not sure whether I get the idea correctly and what is the right way to do that.

In the mentioned paper, they basically want to check whether the open model can outperform the closed variant even if the data are generated by the former. More precisely, they generate an
articial sample of data from the open model with fixed structural parameters, using a random
sequence of shocks. Next, they estimate the open and closed model recursively on this articial
data set, generate forecasts and calculate the RMFSE statistics. In addition, they repeat this procedure multiple times to get a distribution of relative RMFSEs from the two models, conditional on the data generating process coming from the open variant.

The idea is that via this exercise I would be able to tell how these models perform in forecasting even if it is the true data generating process and the prior is correctly specied for the open variant. If the forecasting performance is not much different for both models, ignoring the foreign sector might be a justified decision while forecasting domestic variables. In other words, I would like to check the misspecification of the open model.

I think I get the idea but I do not know how to do that in Dynare. Please, could you help me with this problem?

Thank you very much.

Martin

That should be straightforward. Use something like

stoch_simul(periods=200, order=1);
datatomfile('fsdat_simul', {'gy_obs'; 'gp_obs'});

to simulate the data from one file and then use the datafile in the other one for estimation.

@jpfeifer
Dear professor,

I’d like to ask you for help with the following. Everything that is described in the original post holds, however I have a few questions regarding the artificial data.

Let’s I have already generated artificial data from the open model using stoch_simul(periods=200, order=1). Now, the simulated series are stored in oo_.endo_simul. Given that my original dataset consists of 86 observations, I want to have the same number of obs in the artificial data set, too. Is it alright to take let’s say 100:185 observations from oo_.endo_simul, save it and estimate the open and closed variant using this data? Shouldn’t I somehow transform the simulated series (the models are log-linearized and the original series were transformed accordingly prior to estimation)? I would say I shouldn’t because the model generates the artificial data according to its log-linearized structure. However, some of the series don’t have zero mean by far. I know that the simulated variables have approximately zero means with sufficiently large number of simulated periods but I am afraid I can’t estimate the selected 86 observations as one of the variables has mean of -3.8 for example (with scaling the shocks with 1). Could you please help me with the right procedure of the exercise which I described in the original post?

Thank you a lot.

  1. Yes, simulating more periods and dropping a burnin is usually fine.
  2. When comparing model and data, both series should undergo the same transformation. For example, use percentage deviations from the steady state/balanced growth path.