Corrections for bvar-dsge estimation and irfs.

git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@1341 ac1d8469-bf42-47a9-8791-bf33cf982152
time-shift
adjemian 2007-07-06 08:43:25 +00:00
parent 2074327cd9
commit 269329cac2
2 changed files with 6 additions and 4 deletions

View File

@ -273,7 +273,9 @@ IRF_DSGEs = dir([MhDirectoryName '/' M_.fname '_IRF_DSGEs*.mat']);
NumberOfIRFfiles_dsge = length(IRF_DSGEs);
IRF_BVARDSGEs = dir([MhDirectoryName '/' M_.fname '_IRF_BVARDSGEs*.mat']);
NumberOfIRFfiles_bavrdsge = length(IRF_BVARDSGEs);
NumberOfIRFfiles_dsgevar = length(IRF_BVARDSGEs);
MeanIRF = zeros(options_.irf,nvar,M_.exo_nbr);
MedianIRF = zeros(options_.irf,nvar,M_.exo_nbr);
@ -284,7 +286,7 @@ HPDIRF = zeros(options_.irf,2,nvar,M_.exo_nbr);
if options_.TeX
varlist_TeX = [];
for i=1:nvar
varlist_TeX = strvcat(varlist_TeX,M_.endo_names_tex(SelecVariables(i),:));
varlist_TeX = strvcat(varlist_TeX,M_.endo_names_tex(IndxVariables(i),:));
end
end
@ -347,7 +349,7 @@ if MAX_nirfs_dsgevar
clear STOCK_IRF_BVARDSGE;
for i = 1:M_.exo_nbr
for j = 1:nvar
name = [deblank(M_.endo_names(SelecVariables(j),:)) '_' deblank(tit(i,:))];
name = [deblank(M_.endo_names(IndxVariables(j),:)) '_' deblank(tit(i,:))];
eval(['oo_.PosteriorIRF.bvardsge.Mean.' name ' = MeanIRFdsgevar(:,j,i);']);
eval(['oo_.PosteriorIRF.bvardsge.Median.' name ' = MedianIRFdsgevar(:,j,i);']);
eval(['oo_.PosteriorIRF.bvardsge.Var.' name ' = VarIRFdsgevar(:,j,i);']);

View File

@ -828,7 +828,7 @@ if (any(bayestopt_.pshape >0 ) & options_.mh_replic) | ...
if options_.use_mh_covariance_matrix
invhess = compute_mh_covariance_matrix();
end
if ~options_.bvar-dsge
if ~options_.bvar_dsge
metropolis('DsgeLikelihood',xparam1,invhess,bounds,gend,data);
else
metropolis('DsgeVarLikelihood',xparam1,invhess,bounds,gend);