diff --git a/doc/manual/source/the-model-file.rst b/doc/manual/source/the-model-file.rst index 60edf8911a5f36e5d65e84db081d6d59c88ea44a..8be7dda09c6c6deb447bf1897c950506dcefdf2e 100644 --- a/doc/manual/source/the-model-file.rst +++ b/doc/manual/source/the-model-file.rst @@ -7112,7 +7112,7 @@ observed variables. Probability of extreme values of the prior density in each tail that is ignored when computing bounds for the parameters. Default: - ``1e-10``. + ``1e-10`` for ``posterior_sampling_method=slice`` and ``0`` otherwise . .. option:: huge_number = DOUBLE diff --git a/matlab/+gsa/stability_mapping.m b/matlab/+gsa/stability_mapping.m index 8badb3bc7d23f45c1a520b5883942b27e122c422..b7154f47df2d2bee8a663f11508c2299eba8dd44 100644 --- a/matlab/+gsa/stability_mapping.m +++ b/matlab/+gsa/stability_mapping.m @@ -92,6 +92,10 @@ xparam1=[]; [~,~,~,lb,ub] = set_prior(estim_params_,M_,options_); %Prepare bounds if ~isempty(bayestopt_) && any(bayestopt_.pshape > 0) % Set prior bounds + if options_.prior_trunc==0 + fprintf('\nstability_mapping: GSA with priors requires bounded support. Setting options_.prior_trunc=1e-10.\n') + options_.prior_trunc=1e-10; + end bounds = prior_bounds(bayestopt_, options_.prior_trunc); bounds.lb = max(bounds.lb,lb); bounds.ub = min(bounds.ub,ub); diff --git a/matlab/default_option_values.m b/matlab/default_option_values.m index 300b4c6114fdac8e970ca01769904bd75ffda4bd..929079add12b208366a19ca4451c5d887a9cb333 100644 --- a/matlab/default_option_values.m +++ b/matlab/default_option_values.m @@ -452,7 +452,7 @@ options_.mh_posterior_mode_estimation = false; options_.smc_posterior_mode_estimation = false; options_.prefilter = 0; options_.presample = 0; -options_.prior_trunc = 1e-10; +options_.prior_trunc = 0; options_.smoother = false; options_.smoother_redux = false; options_.posterior_max_subsample_draws = 1200; diff --git a/matlab/estimation/dynare_estimation_init.m b/matlab/estimation/dynare_estimation_init.m index ffa982c0c29a434a867a655288db6e00f0d217b1..60b188432f573d505ed0cd8b489998dc335e2925 100644 --- a/matlab/estimation/dynare_estimation_init.m +++ b/matlab/estimation/dynare_estimation_init.m @@ -117,6 +117,14 @@ if isequal(options_.diffuse_filter,1) || (options_.kalman_algo>2) end end +if strcmp('slice',options_.posterior_sampler_options.posterior_sampling_method) + if options_.prior_trunc==0 + fprintf('\ndynare_estimation_init: slice requires bounded support. Setting options_.prior_trunc=1e-10.\n') + options_.prior_trunc=1e-10; + end +end + + options_=select_qz_criterium_value(options_); % Set options related to filtered variables.