commit
6a6ccfa966
|
@ -7147,7 +7147,7 @@ cannot be less than the number of constrained periods.
|
|||
Number of simulations. Default: @code{5000}.
|
||||
|
||||
@item conf_sig = @var{DOUBLE}
|
||||
Level of significance for confidence interval. Default: @code{0.80}
|
||||
Level of significance for confidence interval. Default: @code{0.90}
|
||||
|
||||
@end table
|
||||
|
||||
|
|
|
@ -103,7 +103,7 @@ end
|
|||
% Plot graphs
|
||||
sims_no_shock_mean = mean(sims_no_shock, 3);
|
||||
|
||||
sort_idx = round((0.5 + [-options_.conf_sig, options_.conf_sig, 0]/2) * options_.bvar_replic);
|
||||
sort_idx = round((0.5 + [-options_.bvar.conf_sig, options_.bvar.conf_sig, 0]/2) * options_.bvar_replic);
|
||||
|
||||
sims_no_shock_sort = sort(sims_no_shock, 3);
|
||||
sims_no_shock_down_conf = sims_no_shock_sort(:, :, sort_idx(1));
|
||||
|
|
|
@ -102,7 +102,7 @@ posterior_mean_irfs = mean(sampled_irfs,4);
|
|||
posterior_variance_irfs = var(sampled_irfs, 1, 4);
|
||||
|
||||
sorted_irfs = sort(sampled_irfs,4);
|
||||
sort_idx = round((0.5 + [-options_.conf_sig, options_.conf_sig, .0]/2) * options_.bvar_replic);
|
||||
sort_idx = round((0.5 + [-options_.bvar.conf_sig, options_.bvar.conf_sig, .0]/2) * options_.bvar_replic);
|
||||
|
||||
posterior_down_conf_irfs = sorted_irfs(:,:,:,sort_idx(1));
|
||||
posterior_up_conf_irfs = sorted_irfs(:,:,:,sort_idx(2));
|
||||
|
|
|
@ -78,7 +78,7 @@ for i=1:horizon
|
|||
sigma_y = sigma_y+sigma_u;
|
||||
end
|
||||
|
||||
fact = norminv((1-options_.conf_sig)/2,0,1);
|
||||
fact = norminv((1-options_.forecasts.conf_sig)/2,0,1);
|
||||
|
||||
int_width = zeros(horizon,M_.endo_nbr);
|
||||
for i=1:nvar
|
||||
|
|
|
@ -74,7 +74,7 @@ for j= 1:nvar
|
|||
fprintf(fidTeX,'\\centering \n');
|
||||
fprintf(fidTeX,'\\includegraphics[scale=0.5]{%s/graphs/forcst%d}\n',dname,n_fig);
|
||||
fprintf(fidTeX,'\\label{Fig:forcst:%d}\n',n_fig);
|
||||
fprintf(fidTeX,'\\caption{Mean forecasts and %2.0f%% confidence intervals}\n',options_.conf_sig*100);
|
||||
fprintf(fidTeX,'\\caption{Mean forecasts and %2.0f%% confidence intervals}\n',options_.forecasts.conf_sig*100);
|
||||
fprintf(fidTeX,'\\end{figure}\n');
|
||||
fprintf(fidTeX,' \n');
|
||||
end
|
||||
|
@ -110,7 +110,7 @@ if m > 1
|
|||
fprintf(fidTeX,'\\centering \n');
|
||||
fprintf(fidTeX,'\\includegraphics[scale=0.5]{%s/graphs/forcst%d}\n',dname,n_fig);
|
||||
fprintf(fidTeX,'\\label{Fig:forcst:%d}\n',n_fig);
|
||||
fprintf(fidTeX,'\\caption{Mean forecasts and %2.0f\\%% confidence intervals}\n',options_.conf_sig*100);
|
||||
fprintf(fidTeX,'\\caption{Mean forecasts and %2.0f\\%% confidence intervals}\n',options_.forecasts.conf_sig*100);
|
||||
fprintf(fidTeX,'\\end{figure}\n');
|
||||
fprintf(fidTeX,' \n');
|
||||
end
|
||||
|
|
|
@ -109,6 +109,7 @@ options_.bvar_prior_mu = 2;
|
|||
options_.bvar_prior_omega = 1;
|
||||
options_.bvar_prior_flat = 0;
|
||||
options_.bvar_prior_train = 0;
|
||||
options_.bvar.conf_sig = 0.6;
|
||||
|
||||
% Initialize the field that will contain the optimization algorigthm's options declared in the
|
||||
% estimation command (if anny).
|
||||
|
@ -305,6 +306,8 @@ options_.prior_draws = 10000;
|
|||
options_.sampling_draws = 500;
|
||||
|
||||
options_.forecast = 0;
|
||||
options_.forecasts.conf_sig = 0.9;
|
||||
options_.conditional_forecast.conf_sig = 0.9;
|
||||
|
||||
% Model
|
||||
options_.linear = 0;
|
||||
|
@ -513,7 +516,7 @@ options_.estimation.moments_posterior_density.gridpoints = 2^9;
|
|||
options_.estimation.moments_posterior_density.bandwidth = 0; % Rule of thumb optimal bandwidth parameter.
|
||||
options_.estimation.moments_posterior_density.kernel_function = 'gaussian'; % Gaussian kernel for Fast Fourrier Transform approximaton.
|
||||
% Misc
|
||||
options_.conf_sig = 0.6;
|
||||
% options_.conf_sig = 0.6;
|
||||
oo_.exo_simul = [];
|
||||
oo_.endo_simul = [];
|
||||
ys0_ = [];
|
||||
|
|
|
@ -63,8 +63,8 @@ if ~isfield(options_cond_fcst,'periods') || isempty(options_cond_fcst.periods)
|
|||
options_cond_fcst.periods = 40;
|
||||
end
|
||||
|
||||
if ~isfield(options_cond_fcst,'conf_sig') || isempty(options_cond_fcst.conf_sig)
|
||||
options_cond_fcst.conf_sig = .8;
|
||||
if ~isfield(options_cond_fcst,'conditional_forecast') || ~isfield(options_cond_fcst.conditional_forecast,'conf_sig') || isempty(options_cond_fcst.conditional_forecast.conf_sig)
|
||||
options_cond_fcst.conditional_forecast.conf_sig = .8;
|
||||
end
|
||||
|
||||
if isequal(options_cond_fcst.parameter_set,'calibration')
|
||||
|
@ -228,7 +228,7 @@ end
|
|||
mFORCS1 = mean(FORCS1,3);
|
||||
mFORCS1_shocks = mean(FORCS1_shocks,3);
|
||||
|
||||
tt = (1-options_cond_fcst.conf_sig)/2;
|
||||
tt = (1-options_cond_fcst.conditional_forecast.conf_sig)/2;
|
||||
t1 = round(options_cond_fcst.replic*tt);
|
||||
t2 = round(options_cond_fcst.replic*(1-tt));
|
||||
|
||||
|
|
|
@ -134,7 +134,7 @@ for i=1:iter
|
|||
sigma_y = sigma_y+sigma_u;
|
||||
end
|
||||
|
||||
fact = norminv((1-options_.conf_sig)/2,0,1);
|
||||
fact = norminv((1-options_.forecasts.conf_sig)/2,0,1);
|
||||
|
||||
int_width = zeros(iter,endo_nbr);
|
||||
for i=1:nvar
|
||||
|
|
|
@ -1727,7 +1727,7 @@ estimation_options : o_datafile
|
|||
| o_nograph
|
||||
| o_nodisplay
|
||||
| o_graph_format
|
||||
| o_conf_sig
|
||||
| o_forecasts_conf_sig
|
||||
| o_mh_conf_sig
|
||||
| o_mh_replic
|
||||
| o_mh_drop
|
||||
|
@ -2145,7 +2145,7 @@ bvar_density : BVAR_DENSITY INT_NUMBER ';'
|
|||
|
||||
bvar_forecast_option : bvar_common_option
|
||||
| o_forecast
|
||||
| o_conf_sig
|
||||
| o_bvar_conf_sig
|
||||
| o_bvar_replic
|
||||
;
|
||||
|
||||
|
@ -2454,7 +2454,7 @@ dynare_sensitivity_option : o_gsa_identification
|
|||
| o_nograph
|
||||
| o_nodisplay
|
||||
| o_graph_format
|
||||
| o_conf_sig
|
||||
| o_forecasts_conf_sig
|
||||
| o_mh_conf_sig
|
||||
| o_loglinear
|
||||
| o_mode_file
|
||||
|
@ -2501,7 +2501,7 @@ forecast_options: forecast_option
|
|||
;
|
||||
|
||||
forecast_option: o_periods
|
||||
| o_conf_sig
|
||||
| o_forecasts_conf_sig
|
||||
| o_nograph
|
||||
| o_nodisplay
|
||||
| o_graph_format
|
||||
|
@ -2517,7 +2517,7 @@ conditional_forecast_options : conditional_forecast_option
|
|||
|
||||
conditional_forecast_option : o_periods
|
||||
| o_replic
|
||||
| o_conf_sig
|
||||
| o_conditional_forecast_conf_sig
|
||||
| o_controlled_varexo
|
||||
| o_parameter_set
|
||||
;
|
||||
|
@ -2823,7 +2823,9 @@ list_allowed_graph_formats : allowed_graph_formats
|
|||
o_subsample_name : symbol EQUAL date_expr ':' date_expr
|
||||
{ driver.set_subsample_name_equal_to_date_range($1, $3, $5); }
|
||||
;
|
||||
o_conf_sig : CONF_SIG EQUAL non_negative_number { driver.option_num("conf_sig", $3); };
|
||||
o_bvar_conf_sig : CONF_SIG EQUAL non_negative_number { driver.option_num("bvar.conf_sig", $3); };
|
||||
o_forecasts_conf_sig : CONF_SIG EQUAL non_negative_number { driver.option_num("forecasts.conf_sig", $3); };
|
||||
o_conditional_forecast_conf_sig : CONF_SIG EQUAL non_negative_number { driver.option_num("conditional_forecast.conf_sig", $3); };
|
||||
o_mh_conf_sig : MH_CONF_SIG EQUAL non_negative_number { driver.option_num("mh_conf_sig", $3); };
|
||||
o_mh_replic : MH_REPLIC EQUAL INT_NUMBER { driver.option_num("mh_replic", $3); };
|
||||
o_posterior_max_subsample_draws : POSTERIOR_MAX_SUBSAMPLE_DRAWS EQUAL INT_NUMBER { driver.option_num("posterior_max_subsample_draws", $3); };
|
||||
|
|
Loading…
Reference in New Issue