Page 1 of 1
Saved posterior theoretical moments
Posted:
Wed Sep 18, 2013 8:35 am
by gin
Dear all,
Where are the posterior theoretical moments (mean, std) saved (apart from the log file)? I conjecture that the mean should be taken from the oo_.steady_state, although it would be nice to see it in the oo_.PosteriorTheoreticalMoments as well. But I cannot find the std: I presume it should be in the oo_.PosteriorTheoreticalMoments.dsge.covariance `mean' or `variance' structure but both deliver NaNs for all variables although the log file gives reasonable numerical values.
Version:4.3.3.
gin
Re: Saved posterior theoretical moments
Posted:
Wed Sep 18, 2013 8:38 am
by jpfeifer
Please provide the mod-file.
Re: Saved posterior theoretical moments
Posted:
Wed Sep 18, 2013 9:11 am
by gin
Both the mod and the log files attached.
Additionally, (the same mod-file but should be under a different subject) I'm asking the estimation command for the k-step ahead forecasts but no output is provided in the oo_ structure:
- Code: Select all
estimation(order=1,datafile=ctwBaselineData, mh_replic=300000, mh_nblocks=1, mh_drop=.3, mh_jscale=0.2,
mode_compute=6, filter_step_ahead = [1 4 8 12], forecast=20,smoother, filtered_vars, diffuse_filter,
nodisplay,
% do this only for the final model b/c takes a lot of time
moments_varendo,
conditional_variance_decomposition=[1 4 8 20],
%
graph_format=(eps,pdf))
Re: Saved posterior theoretical moments
Posted:
Wed Sep 18, 2013 11:37 am
by jpfeifer
I cannot run the mod-file. What else does one need? A steady state file? Data file?
Re: Saved posterior theoretical moments
Posted:
Wed Sep 18, 2013 12:10 pm
by gin
All the required files are attached. Please, change the .txt extension to .mat extension.
Re: Saved posterior theoretical moments
Posted:
Thu Sep 19, 2013 1:12 pm
by jpfeifer
Try the most recent snapshot. Moreover, some of the moments are saved in fields like oo_.posterior_mean
Re: Saved posterior theoretical moments
Posted:
Fri Sep 20, 2013 8:35 am
by gin
Still with ver.4.3.3.:
As far as I understood, this happens when some of the variables are nonstationary, i.e., would result in the `NaN' value. Then, the log-file reports NaN values only for the nonstationary variables but the oo_ structure yields all NaNs regardless of stationarity.
Repeating the exercise without the nonstationary variables, the oo_ structure gives numerical values. However, the values in the `oo_.PosteriorTheoreticalMoments.dsge.covariance.mean' structure slightly differ from the ones reported in the log-file under the title `Theoretical moments'.
Re: Saved posterior theoretical moments
Posted:
Fri Sep 20, 2013 11:46 am
by jpfeifer
I am not sure I am following here.
Theoretical moments are displayed only in the log file for stoch_simul. Those moments are based on the posterior mean of the parameters when called after estimation.
But the posterior moments stored in oo_ are the mean of the posterior moments (given parameter draws from the posterior distribution). This is different than the moments at the mean of the parameters.
Re: Saved posterior theoretical moments
Posted:
Mon Sep 23, 2013 8:06 am
by gin
Got it.
And the stoch_simul moments are in oo_.mean and oo_.var.