Skip to content
Snippets Groups Projects
Commit e214ec29 authored by Johannes Pfeifer's avatar Johannes Pfeifer Committed by Stéphane Adjemian
Browse files

Allow for parameter_set=mle_mode in conditional_forecast

parent 1c420e60
Branches
Tags
No related merge requests found
......@@ -46,7 +46,13 @@ function imcforecast(constrained_paths, constrained_vars, options_cond_fcst)
global options_ oo_ M_ bayestopt_
if ~isfield(options_cond_fcst,'parameter_set') || isempty(options_cond_fcst.parameter_set)
options_cond_fcst.parameter_set = 'posterior_mode';
if isfield(oo_,'posterior_mode')
options_cond_fcst.parameter_set = 'posterior_mode';
elseif isfield(oo_,'mle_mode')
options_cond_fcst.parameter_set = 'mle_mode';
else
error('No valid parameter set found')
end
end
if ~isfield(options_cond_fcst,'replic') || isempty(options_cond_fcst.replic)
......@@ -82,6 +88,9 @@ if estimated_model
case 'posterior_median'
xparam = get_posterior_parameters('median');
graph_title='Posterior Median';
case 'mle_mode'
xparam = get_posterior_parameters('mode','mle_');
graph_title='ML Mode';
case 'prior_mode'
xparam = bayestopt_.p5(:);
graph_title='Prior Mode';
......
......@@ -164,3 +164,13 @@ end
shock_decomposition;
conditional_forecast_paths;
var gy_obs;
periods 1 2 3:5;
values 0.01 -0.02 0;
var gp_obs;
periods 1:5;
values 0.05;
end;
conditional_forecast(parameter_set=mle_mode, controlled_varexo=(e_a,e_m));
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment