Commit 76ca912d authored by Sébastien Villemot's avatar Sébastien Villemot
Browse files

Merge pull request #343 from JohannesPfeifer/master

Bugfixes of correlation_mc_analysis
parents c9a15f0a 9e9f882c
......@@ -4609,7 +4609,8 @@ where @var{THEORETICAL_MOMENT} is one of the following:
Variance-covariance of endogenous variables
@item correlation
Autocorrelation of endogenous variables
Auto- and cross-correlation of endogenous variables. Fields are vectors with correlations from 1 up to order @code{options_.ar}
@item VarianceDecomposition
Decomposition of variance@footnote{When the shocks are correlated, it
......
......@@ -49,9 +49,9 @@ if isfield(oo_,[TYPE 'TheoreticalMoments'])
eval(['temporary_structure = oo_.' TYPE 'TheoreticalMoments.dsge;'])
if isfield(temporary_structure,'correlation')
eval(['temporary_structure = oo_.' TYPE 'TheoreticalMoments.dsge.correlation.Mean;'])
if isfield(temporary_structure,var1)
if isfield(temporary_structure,deblank(var1))
eval(['temporary_structure_1 = oo_.' TYPE 'TheoreticalMoments.dsge.correlation.Mean.' var1 ';'])
if isfield(temporary_structure_1,var2)
if isfield(temporary_structure_1,deblank(var2))
eval(['temporary_structure_2 = temporary_structure_1.' var2 ';'])
l1 = length(temporary_structure_2);
if l1<nar
......@@ -116,7 +116,7 @@ else
if isfield(temporary_structure,'correlation')
oo_ = fill_output_structure(var1,var2,TYPE,oo_,'Mean',nar,NaN);
oo_ = fill_output_structure(var1,var2,TYPE,oo_,'Median',nar,NaN);
oo_ = fill_output_structure(var1,var2,TYPE,oo_,'Nariance',nar,NaN);
oo_ = fill_output_structure(var1,var2,TYPE,oo_,'Variance',nar,NaN);
oo_ = fill_output_structure(var1,var2,TYPE,oo_,'HPDinf',nar,NaN);
oo_ = fill_output_structure(var1,var2,TYPE,oo_,'HPDsup',nar,NaN);
oo_ = fill_output_structure(var1,var2,TYPE,oo_,'deciles',nar,NaN);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment