| 1 |
/* |
| 2 |
* Copyright © 2004-2020 Dynare Team |
| 3 |
* |
| 4 |
* This file is part of Dynare. |
| 5 |
* |
| 6 |
* Dynare is free software: you can redistribute it and/or modify |
| 7 |
* it under the terms of the GNU General Public License as published by |
| 8 |
* the Free Software Foundation, either version 3 of the License, or |
| 9 |
* (at your option) any later version. |
| 10 |
* |
| 11 |
* Dynare is distributed in the hope that it will be useful, |
| 12 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 14 |
* GNU General Public License for more details. |
| 15 |
* |
| 16 |
* You should have received a copy of the GNU General Public License |
| 17 |
* along with Dynare. If not, see <https://www.gnu.org/licenses/>. |
| 18 |
*/ |
| 19 |
|
| 20 |
@#include "fs2000.inc" |
| 21 |
|
| 22 |
estimation(order=1, datafile='../fsdat_simul', nobs=192,silent_optimizer, loglinear, mh_replic=10000, mh_nblocks=1, mh_tune_jscale=0.33,mh_tune_guess=0.7,plot_priors=0); |
| 23 |
|
| 24 |
mhdata = load('fs2000/metropolis/fs2000_mh_history_0.mat'); |
| 25 |
|
| 26 |
if any(abs(mhdata.record.AcceptanceRatio-options_.mh_tune_jscale.target)>options_.mh_tune_jscale.c2) |
| 27 |
error('Automagic tuning of the MCMC proposal scale parameter did not work as expected!') |
| 28 |
end |