Clarify theoretical second moments for order=2

Eliminates warning message introduced in
4c8f3a89cc
Adds hint to approximation in table title and adds the information with
a reference to Kim/Kim/Schaumburg/Sims (2008) to manual.
closes #278
time-shift
Johannes Pfeifer 2013-03-18 22:58:06 +01:00
parent c85338f022
commit 1883eb092b
4 changed files with 23 additions and 12 deletions

View File

@ -3161,7 +3161,7 @@ period(s). The periods must be strictly positive. Conditional variances are give
decomposition provides the decomposition of the effects of shocks upon
impact. The results are stored in
@code{oo_.conditional_variance_decomposition}
(@pxref{oo_.conditional_variance_decomposition}). The variance decomposition is only conducted, if theoretical moments are requested, i.e. using the @code{periods=0}-option. Currently, variance decompositions are only implemented for @code{order=1}. In case of @code{order=2}, Dynare will thus not display the variance decomposition based on a second order approximation, but on a first order approximation.
(@pxref{oo_.conditional_variance_decomposition}). The variance decomposition is only conducted, if theoretical moments are requested, i.e. using the @code{periods=0}-option. In case of @code{order=2}, Dynare provides a second-order accurate approximation to the true second moments based on the linear terms of the second-order solution (see @cite{Kim, Kim, Schaumburg and Sims (2008)}).
@item pruning
Discard higher order terms when iteratively computing simulations of
@ -3292,7 +3292,7 @@ in declaration order.
@defvr {MATLAB/Octave variable} oo_.var
After a run of @code{stoch_simul}, contains the variance-covariance of
the endogenous variables. Contains theoretical variance if the
@code{periods} option is not present, and empirical variance
@code{periods} option is not present (or an approximation thereof for @code{order=2}), and empirical variance
otherwise. The variables are arranged in declaration order.
@end defvr
@ -3303,7 +3303,7 @@ autocorrelation matrices of the endogenous variables. The element
number of the matrix in the cell array corresponds to the order of
autocorrelation. The option @code{ar} specifies the number of
autocorrelation matrices available. Contains theoretical
autocorrelations if the @code{periods} option is not present, and
autocorrelations if the @code{periods} option is not present (or an approximation thereof for @code{order=2}), and
empirical autocorrelations otherwise.
The element @code{oo_.autocorr@{i@}(k,l)} is equal to the correlation
@ -3338,6 +3338,8 @@ If a second order approximation has been requested, contains the
vector of the mean correction terms.
@end table
In case of @code{order=2}, the theoretical second moments are a second order accurate approximation of the true second moments, see @code{conditional_variance_decomposition}.
@end defvr
@defvr {MATLAB/Octave variable} oo_.irfs

View File

@ -51,7 +51,11 @@ oo_.mean = m;
oo_.var = oo_.gamma_y{1};
if ~options_.noprint %options_.nomoments == 0
title='THEORETICAL MOMENTS';
if options_.order == 2
title='APROXIMATED THEORETICAL MOMENTS';
else
title='THEORETICAL MOMENTS';
end
if options_.hp_filter
title = [title ' (HP filter, lambda = ' num2str(options_.hp_filter) ')'];
end
@ -62,7 +66,7 @@ if ~options_.noprint %options_.nomoments == 0
if M_.exo_nbr > 1 && size(stationary_vars, 1) > 0
disp(' ')
if options_.order == 2
title='VARIANCE DECOMPOSITION (in percent), based on first order approximation';
title='APPROXIMATED VARIANCE DECOMPOSITION (in percent)';
else
title='VARIANCE DECOMPOSITION (in percent)';
end
@ -97,7 +101,11 @@ if options_.nocorr == 0 && size(stationary_vars, 1) > 0
corr = oo_.gamma_y{1}(i1,i1)./(sd(i1)*sd(i1)');
if ~options_.noprint,
disp(' ')
title='MATRIX OF CORRELATIONS';
if options_.order == 2
title='APPROXIMATED MATRIX OF CORRELATIONS';
else
title='MATRIX OF CORRELATIONS';
end
if options_.hp_filter
title = [title ' (HP filter, lambda = ' num2str(options_.hp_filter) ')'];
end
@ -115,7 +123,11 @@ if options_.ar > 0 && size(stationary_vars, 1) > 0
end
if ~options_.noprint,
disp(' ')
title='COEFFICIENTS OF AUTOCORRELATION';
if options_.order == 2
title='APPROXIMATED COEFFICIENTS OF AUTOCORRELATION';
else
title='COEFFICIENTS OF AUTOCORRELATION';
end
if options_.hp_filter
title = [title ' (HP filter, lambda = ' num2str(options_.hp_filter) ')'];
end

View File

@ -51,7 +51,7 @@ conditional_decomposition_array = conditional_variance_decomposition(StateSpaceM
if options_.noprint == 0
if options_.order == 2
disp(' ')
disp('CONDITIONAL VARIANCE DECOMPOSITION (in percent), based on first order approximation')
disp('APPROXIMATED CONDITIONAL VARIANCE DECOMPOSITION (in percent)')
else
disp(' ')
disp('CONDITIONAL VARIANCE DECOMPOSITION (in percent)')

View File

@ -122,7 +122,7 @@ end
if options_.periods > 0 && ~PI_PCL_solver
if options_.periods <= options_.drop
disp(['STOCH_SIMUL error: The horizon of simulation is shorter' ...
' than the number of observations to be DROPed'])
' than the number of observations to be dropped'])
options_ =options_old;
return
end
@ -142,9 +142,6 @@ if options_.nomoments == 0
elseif options_.periods == 0
% There is no code for theoretical moments at 3rd order
if options_.order <= 2
if options_.order == 2
warning('You have requested a second order approximation, but variance decompositions currently only allow for first order. Displaying decompositions at order=1 instead.')
end
disp_th_moments(oo_.dr,var_list);
end
else