clean up sbvar code
parent
796c98fc16
commit
09df8bcf77
|
@ -257,32 +257,16 @@ options_.discretionary_policy = 0;
|
|||
% Shock decomposition
|
||||
options_.parameter_set = [];
|
||||
|
||||
% SBVAR & MS SBVAR initializations:
|
||||
% SBVAR
|
||||
options_.ms.vlistlog = [];
|
||||
options_.ms.restriction_fname = 0;
|
||||
options_.ms.forecast = 1;
|
||||
options_.ms.cross_restrictions = 0;
|
||||
options_.ms.contemp_reduced_form = 0;
|
||||
options_.ms.real_pseudo_forecast = 0;
|
||||
options_.ms.dummy_obs = 0;
|
||||
options_.ms.nstates = 2;
|
||||
options_.ms.indxscalesstates = 0;
|
||||
options_.ms.q_diag = 0.85;
|
||||
options_.ms.flat_prior = 0;
|
||||
options_.ms.ncsk = 0;
|
||||
options_.ms.nstd = 6;
|
||||
options_.ms.ninv = 1000;
|
||||
options_.ms.indxparr = 1;
|
||||
options_.ms.indxovr = 0;
|
||||
options_.ms.aband = 1;
|
||||
options_.ms.indxap = 1;
|
||||
options_.ms.apband = 1;
|
||||
options_.ms.indximf = 1;
|
||||
options_.ms.imfband = 1;
|
||||
options_.ms.indxfore = 0;
|
||||
options_.ms.foreband = 0;
|
||||
options_.ms.indxgforhat = 1;
|
||||
options_.ms.cnum = 0;
|
||||
options_.ms.indxgimfhat = 1;
|
||||
options_.ms.indxestima = 1;
|
||||
options_.ms.indxgdls = 1;
|
||||
|
@ -290,14 +274,27 @@ options_.ms.cms =0;
|
|||
options_.ms.ncms = 0;
|
||||
options_.ms.eq_cms = 1;
|
||||
options_.ms.banact = 1;
|
||||
options_.ms.lower_cholesky = 0;
|
||||
options_.ms.upper_cholesky = 0;
|
||||
options_.ms.log_var = [];
|
||||
options_.ms.vlistlog = [];
|
||||
options_.ms.Qi = [];
|
||||
options_.ms.Ri = [];
|
||||
%options_.ms.nstates = 2;
|
||||
%options_.ms.indxscalesstates = 0;
|
||||
%options_.ms.q_diag = 0.85;
|
||||
%options_.ms.flat_prior = 0;
|
||||
%options_.ms.nstd = 6;
|
||||
%options_.ms.ninv = 1000;
|
||||
%options_.ms.indxparr = 1;
|
||||
%options_.ms.indxovr = 0;
|
||||
%options_.ms.aband = 1;
|
||||
%options_.ms.indxap = 1;
|
||||
%options_.ms.apband = 1;
|
||||
%options_.ms.indximf = 1;
|
||||
%options_.ms.imfband = 1;
|
||||
%options_.ms.indxfore = 0;
|
||||
%options_.ms.foreband = 0;
|
||||
%options_.ms.cnum = 0;
|
||||
|
||||
% MS Sbvar options
|
||||
% MS SBVAR (and some SBVAR)
|
||||
options_ = initialize_ms_sbvar_options(M_, options_);
|
||||
|
||||
% saved graph formats
|
||||
|
|
|
@ -74,7 +74,7 @@ nconstr1=nfqm; % number of the 1st set of constraints
|
|||
nconstr2=options_.forecast ; % number of the 2nd set of constraints
|
||||
nconstr=nconstr1+nconstr2; % q: 4 years -- 4*12 months.
|
||||
% When 0, no conditions directly on variables <<>>
|
||||
nconstr=0 %6*nconstr1;
|
||||
nconstr=0 ; %6*nconstr1;
|
||||
options_.ms.eq_ms = []; % location of MS equation; if [], all shocks
|
||||
PorR = [4*ones(nconstr1,1);2*ones(nconstr1,1);3*ones(nconstr1,1)]; % the variable conditioned. 1: Pcm; 3: FFR; 4: CPI
|
||||
PorR = [PorR;1*ones(nconstr1,1);5*ones(nconstr1,1);6*ones(nconstr1,1)];
|
||||
|
|
|
@ -111,7 +111,6 @@ indxDummy = options_.ms.bayesian_prior; % 1: add dummy observations to the data
|
|||
%end
|
||||
%=== The following mu is effective only if options_.ms.bayesian_prior==1.
|
||||
mu = zeros(6,1); % hyperparameters
|
||||
mu = zeros(6,1); % hyperparameters
|
||||
mu(1) = 0.57;
|
||||
mu(2) = 0.13;
|
||||
mu(3) = 0.1;
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
function ms_sbvar(M, options)
|
||||
function sbvar(M, options)
|
||||
|
||||
clean_ms_files(M.fname);
|
||||
|
||||
|
@ -8,11 +8,6 @@ if options.forecast == 0
|
|||
options.forecast = 4;
|
||||
end
|
||||
|
||||
options.ms.output_file_tag = M.fname;
|
||||
%options.ms.markov_file = 'specification_2v2c.dat';
|
||||
%options.ms.mhm_file = 'MHM_input.dat';
|
||||
%options.ms.restriction_fname = 'ftd_upperchol3v';
|
||||
|
||||
if options.ms.upper_cholesky
|
||||
if options.ms.lower_cholesky
|
||||
error(['Upper Cholesky and lower Cholesky decomposition can''t be ' ...
|
|
@ -918,7 +918,7 @@ void
|
|||
SBVARStatement::writeOutput(ostream &output, const string &basename) const
|
||||
{
|
||||
options_list.writeOutput(output);
|
||||
output << "ms_sbvar(M_,options_);" << endl;
|
||||
output << "sbvar(M_,options_);" << endl;
|
||||
}
|
||||
|
||||
MSSBVAREstimationStatement::MSSBVAREstimationStatement(const OptionsList &options_list_arg) :
|
||||
|
|
Loading…
Reference in New Issue