From 52ba71bafbfdc3b1e8752b93a440b3a3877a80bd Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?St=C3=A9phane=20Adjemian=20=28Charybdis=29?=
 <stephane.adjemian@univ-lemans.fr>
Date: Fri, 12 Apr 2013 18:24:22 +0200
Subject: [PATCH] Moved up the section where bayestopt_.jscale is updated

---
 matlab/dynare_estimation_init.m | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/matlab/dynare_estimation_init.m b/matlab/dynare_estimation_init.m
index e403df3a37..4e891c38a3 100644
--- a/matlab/dynare_estimation_init.m
+++ b/matlab/dynare_estimation_init.m
@@ -319,6 +319,10 @@ if options_.analytic_derivation,
     end
 end
 
+% If jscale isn't specified for an estimated parameter, use global option options_.jscale, set to 0.2, by default.
+k = find(isnan(bayestopt_.jscale));
+bayestopt_.jscale(k) = options_.mh_jscale;
+
 % Test if the dataset is declared.
 if isempty(options_.datafile) && isempty(options_.dataset) 
     if gsa_flag
@@ -329,10 +333,6 @@ if isempty(options_.datafile) && isempty(options_.dataset)
     end
 end
 
-% If jscale isn't specified for an estimated parameter, use global option options_.jscale, set to 0.2, by default.
-k = find(isnan(bayestopt_.jscale));
-bayestopt_.jscale(k) = options_.mh_jscale;
-
 % Take data in logs?
 logged_data_flag = 0;
 if options_.loglinear && ~options_.logdata
-- 
GitLab