How are "moments of simulated variables" computed in Dynare

This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location where you will have to reset your password.
Forum rules
This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location (https://forum.dynare.org) where you will have to reset your password.

How are "moments of simulated variables" computed in Dynare

Postby xh@econ » Mon Oct 12, 2015 9:05 pm

Dear all,

I'm trying to understand the "moments of simulated variables" reported by Dynare. But I have some questions about how these moments are calculated.

I use the following code to simulate the model:
stoch_simul(order=3,irf=60,pruning,periods=200,hp_filter=1600) K C I;

Then I use the simulated series stored in the file "oo_.endo_simul" to work out the moments. However, they are quite different from the reported moments in the output window.

For example, I take the simulated series of C as
sim_C = oo_.endo_simul(declare_order_C,:);
Then I compute mean(sim_C), which is slightly different from the mean reported. But the std(sim_C), skewness(sim_C) and kurtosis(sim_C) are at odds with those reported by Dynare.

I cannot figure out where the problem is. Can anyone give me some help? I really appreciate it.
xh@econ
 
Posts: 1
Joined: Tue Sep 01, 2015 2:27 am

Re: How are "moments of simulated variables" computed in Dyn

Postby jpfeifer » Tue Oct 13, 2015 8:25 am

Dynare provides moments of the filtered variables (hp_filter=1600) in your case. However, the simulated variables in the workspace are the unfiltered ones. To compare them to the reported filtered moments, you would have to filter them.
------------
Johannes Pfeifer
University of Cologne
https://sites.google.com/site/pfeiferecon/
jpfeifer
 
Posts: 6940
Joined: Sun Feb 21, 2010 4:02 pm
Location: Cologne, Germany


Return to Dynare help

Who is online

Users browsing this forum: No registered users and 9 guests