Commit Graph

18 Commits (237aa465d23fb3113a27cf2d8f9932bd3c2e2e8f)

Author SHA1 Message Date
Johannes Pfeifer fa739c3a63 posterior_sampler_initialization.m: update record if different sampler is used
Also removes redundant field
2021-01-22 15:01:23 +01:00
Johannes Pfeifer c78890d5ca posterior_sampler_initialization.m: Allow running different samplers after each other
Transform error to warning
2021-01-22 15:01:22 +01:00
Johannes Pfeifer 32bdb82cf8 Make load_mh_file honor use_mh_covariance option 2021-01-22 15:01:02 +01:00
Johannes Pfeifer 9e5cb1422d
Save jscale to record structure before running MCMC
Useful in conjunction with mh_tune_jscale in cases where the posterior sampler crashes
2020-02-29 10:28:50 +01:00
Sébastien Villemot 49dc997073
Global reindentation of MATLAB code (excluding submodules)
Also convert to Unix end-of-lines, and remove trailing whitespaces.
2019-12-20 16:30:27 +01:00
Marco Ratto da4baa5d50 make mh_recover robust to crashed parallel jobs 2019-12-12 22:24:30 +01:00
Johannes Pfeifer d4ed77c67e posterior_sampler_initialization.m: provide missing function input
Fixes #1622
2019-09-06 23:03:07 +02:00
Marco Ratto 47900a5909 trap slice sampler when doing mh_recover
(cherry picked from commit 4ba9c9296f1939fa14b1401886d9e9b86541e5e3)
2019-01-17 09:50:07 +00:00
Stéphane Adjemian (Charybdis) 5417b27ac7 Fixed indentation of matlab files. 2017-05-16 15:10:20 +02:00
Stéphane Adjemian (Charybdis) a53636e24e Fixed copyright notices. 2017-05-16 14:11:15 +02:00
Stéphane Adjemian (Charybdis) 88e1701289 Removed useless commas and semicolons. 2017-05-16 13:24:46 +02:00
Marco Ratto 0a40cdf064 Bud fix for cases where record does not contain proposal covariance. 2016-11-07 17:18:41 +01:00
Johannes Pfeifer 7ff6c5b2b7 Cosmetic change to posterior_sampler_initialization.m 2016-10-03 22:10:00 +02:00
Johannes Pfeifer b3877b3a9e Save chain's proposal density and make load_mh_file and mh_recover load it
Closes #504
2016-06-14 15:09:05 +02:00
Marco Ratto 7b3c42c6e1 provisions for reworked posterior sampling options:
- handle sub lists of individual samplers
- split checks in dynare_estimation_init.m and before running posterior_sampler.m [invhess checks]
- posterior sampler options checks moved from initial_estimation_checks.m to check_posterior_sampler_options.m
- added use_mh_covariance_matrix to imh and rwmh
- slice re-sets mode_compute=0 cova_compute=0
- updated test function
2016-05-19 14:37:05 +02:00
Marco Ratto 4445f17efa Manual merge with commit history of metropolis_hastings_initialization.m and random_walk_metropolis_hastings_core.m 2016-05-19 14:34:09 +02:00
Marco Ratto 357e3c2ac7 Make posterior_sampler_initialization.m compatible with new form of prior_draw.m 2016-05-19 14:34:09 +02:00
Marco Ratto c30b6f20a6 Added routines that factor out posterior samplers into the iteration routine posterior_sampler_iteration.m.
It generalizes the random_walk_metropolis_hastings.m structure but adds two new items:
- check_posterior_sampler_options.m which is a wrapper for method specific options (stored in options_.posterior_options)
- posterior_sampler_iteration.m which is a wrapper of the individual iteration of any posterior sampler.

It already embeds, with parallelization implementation:
- random_walk metropolis hastings
- independent metropolis hastings
- slice sampler

It also contains a quick fix for TARB, although the latter should be embedded in posterior_sampler_iteration.m as well.

Any new posterior sampler can be simply added to posterior_sampler_iteration.m, with  wrapper to specific iterations in check_posterior_sampler_options.m
2016-05-19 14:34:09 +02:00