Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Johannes Pfeifer
dynare
Commits
440a0e46
Unverified
Commit
440a0e46
authored
Jul 22, 2021
by
Johannes Pfeifer
Committed by
Sébastien Villemot
Jul 23, 2021
Browse files
Storage of results: use subfolder
Ref.
#1758
parent
263e97da
Changes
91
Hide whitespace changes
Inline
Side-by-side
doc/manual/source/running-dynare.rst
View file @
440a0e46
...
...
@@ -548,7 +548,8 @@ by the ``dynare`` command.
results in the workspace available for further processing. More
details are given under the relevant computing tasks. The
``M_``,``oo_``, and ``options_`` structures are saved in a file
called ``FILENAME_results.mat``. If they exist, ``estim_params_``,
called ``FILENAME_results.mat`` located in the ``MODFILENAME/Output`` folder.
If they exist, ``estim_params_``,
``bayestopt_``, ``dataset_``, ``oo_recursive_`` and
``estimation_info`` are saved in the same file. Note that Matlab
by default only allows ``.mat``-files up to 2GB. You can lift this
...
...
doc/manual/source/the-model-file.rst
View file @
440a0e46
...
...
@@ -3890,7 +3890,8 @@ Computing the stochastic solution
requested (i.e. ``periods`` :math:`>` 0). Note that if this
option is greater than 1, the additional series will not be
used for computing the empirical moments but will simply be
saved in binary form to the file ``FILENAME_simul``. Default:
saved in binary form to the file ``FILENAME_simul`` in the
``FILENAME/Output``-folder. Default:
``1``.
.. option:: solve_algo = INTEGER
...
...
@@ -5297,7 +5298,8 @@ block decomposition of the model (see :opt:`block`).
achieve an acceptance rate of
:ref:`AcceptanceRateTarget<art>`. The resulting scale parameter
will be saved into a file named
``MODEL_FILENAME_mh_scale.mat.`` This file can be loaded in
``MODEL_FILENAME_mh_scale.mat`` in the ``FILENAME/Output``-folder.
This file can be loaded in
subsequent runs via the ``posterior_sampler_options`` option
:ref:`scale_file <scale-file>`. Both ``mode_compute=6`` and
``scale_file`` will overwrite any value specified in
...
...
@@ -5378,7 +5380,8 @@ block decomposition of the model (see :opt:`block`).
Name
of
the
file
containing
previous
value
for
the
mode
.
When
computing
the
mode
,
Dynare
stores
the
mode
(``
xparam1
``)
and
the
hessian
(``
hh
``,
only
if
``
cova_compute
=
1
``)
in
a
file
called
``
MODEL_FILENAME_mode
.
mat
``.
After
a
successful
run
of
called
``
MODEL_FILENAME_mode
.
mat
``
in
the
``
FILENAME
/
Output
``-
folder
.
After
a
successful
run
of
the
estimation
command
,
the
``
mode_file
``
will
be
disabled
to
prevent
other
function
calls
from
implicitly
using
an
updated
``
mode
-
file
``.
Thus
,
if
the
mod
-
file
contains
subsequent
...
...
matlab/compute_mh_covariance_matrix.m
View file @
440a0e46
...
...
@@ -78,4 +78,4 @@ hh = inv(posterior_covariance);
fval
=
posterior_kernel_at_the_mode
;
parameter_names
=
bayestopt_
.
name
;
save
([
M_
.
fname
'_mh_mode.mat'
],
'xparam1'
,
'hh'
,
'fval'
,
'parameter_names'
);
\ No newline at end of file
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_mh_mode.mat'
],
'xparam1'
,
'hh'
,
'fval'
,
'parameter_names'
);
\ No newline at end of file
matlab/dynare_estimation.m
View file @
440a0e46
...
...
@@ -101,7 +101,7 @@ if nnobs>1 || nfirstobs > 1
end
dynare_estimation_1
(
var_list
,
M_
.
dname
);
if
isequal
(
i
,
1
)
&&
options_
.
mode_compute
~=
0
options_
.
mode_file
=
[
M_
.
fname
'_mode'
];
options_
.
mode_file
=
[
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_mode'
];
end
if
options_
.
recursive_estimation_restart
for
j
=
1
:
options_
.
recursive_estimation_restart
...
...
matlab/dynare_estimation_1.m
View file @
440a0e46
...
...
@@ -31,6 +31,10 @@ function dynare_estimation_1(var_list_,dname)
global
M_
options_
oo_
estim_params_
bayestopt_
dataset_
dataset_info
if
~
exist
([
M_
.
dname
filesep
'Output'
],
'dir'
)
mkdir
(
M_
.
dname
,
'Output'
);
end
if
isempty
(
estim_params_
)
mode_compute_o
=
options_
.
mode_compute
;
mh_replic_o
=
options_
.
mh_replic
;
...
...
@@ -206,7 +210,7 @@ if ~isequal(options_.mode_compute,0) && ~options_.mh_posterior_mode_estimation
newratflag
=
new_rat_hess_info
.
newratflag
;
new_rat_hess_info
=
new_rat_hess_info
.
new_rat_hess_info
;
elseif
isnumeric
(
options_
.
mode_compute
)
&&
options_
.
mode_compute
==
6
%save scaling factor
save
([
M_
.
fname
'_optimal_mh_scale_parameter.mat'
],
'Scale'
);
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_optimal_mh_scale_parameter.mat'
],
'Scale'
);
options_
.
mh_jscale
=
Scale
;
bayestopt_
.
jscale
(:)
=
options_
.
mh_jscale
;
end
...
...
@@ -260,9 +264,9 @@ if ~isequal(options_.mode_compute,0) && ~options_.mh_posterior_mode_estimation
end
parameter_names
=
bayestopt_
.
name
;
if
options_
.
cova_compute
||
options_
.
mode_compute
==
5
||
options_
.
mode_compute
==
6
save
([
M_
.
fname
'_mode.mat'
],
'xparam1'
,
'hh'
,
'parameter_names'
,
'fval'
);
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_mode.mat'
],
'xparam1'
,
'hh'
,
'parameter_names'
,
'fval'
);
else
save
([
M_
.
fname
'_mode.mat'
],
'xparam1'
,
'parameter_names'
,
'fval'
);
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_mode.mat'
],
'xparam1'
,
'parameter_names'
,
'fval'
);
end
end
...
...
@@ -375,7 +379,7 @@ end
if
np
>
0
pindx
=
estim_params_
.
param_vals
(:,
1
);
save
([
M_
.
fname
'_params.mat'
],
'pindx'
);
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_params.mat'
],
'pindx'
);
end
switch
options_
.
MCMC_jumping_covariance
...
...
@@ -472,7 +476,7 @@ if (any(bayestopt_.pshape >0 ) && options_.mh_replic) || ...
else
%get stored results if required
if
options_
.
load_mh_file
&&
options_
.
load_results_after_load_mh
oo_load_mh
=
load
([
M_
.
fname
'_results'
],
'oo_'
);
oo_load_mh
=
load
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_results'
],
'oo_'
);
end
if
~
options_
.
nodiagnostic
if
(
options_
.
mh_replic
>
0
||
(
options_
.
load_mh_file
&&
~
options_
.
load_results_after_load_mh
))
...
...
@@ -778,7 +782,7 @@ end
if
np
>
0
pindx
=
estim_params_
.
param_vals
(:,
1
);
save
([
M_
.
fname
'_pindx.mat'
]
,
'pindx'
);
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_pindx.mat'
]
,
'pindx'
);
end
%reset qz_criterium
...
...
matlab/gsa/filt_mc_.m
View file @
440a0e46
...
...
@@ -92,11 +92,11 @@ if ~isempty(options_.mode_file)
load
(
options_
.
mode_file
,
'xparam1'
)
end
if
options_
.
opt_gsa
.
ppost
c
=
load
([
fname_
,
'_mean.mat'
],
'xparam1'
);
c
=
load
([
M_
.
dname
filesep
'Output'
filesep
fname_
,
'_mean.mat'
],
'xparam1'
);
xparam1_mean
=
c
.
xparam1
;
clear
c
elseif
~
isempty
(
options_
.
mode_file
)
&&
exist
([
fname_
,
'_mean.mat'
])
==
2
c
=
load
([
fname_
,
'_mean.mat'
],
'xparam1'
);
elseif
~
isempty
(
options_
.
mode_file
)
&&
exist
([
M_
.
dname
filesep
'Output'
filesep
fname_
,
'_mean.mat'
])
==
2
c
=
load
([
M_
.
dname
filesep
'Output'
filesep
fname_
,
'_mean.mat'
],
'xparam1'
);
xparam1_mean
=
c
.
xparam1
;
clear
c
end
...
...
matlab/marginal_density.m
View file @
440a0e46
...
...
@@ -66,7 +66,7 @@ end
% (usefull if the user wants to perform some computations using
% the posterior mean instead of the posterior mode ==> ).
parameter_names
=
bayestopt_
.
name
;
save
([
M_
.
fname
'_mean.mat'
],
'xparam1'
,
'hh'
,
'parameter_names'
,
'SIGMA'
);
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_mean.mat'
],
'xparam1'
,
'hh'
,
'parameter_names'
,
'SIGMA'
);
fprintf
(
'Estimation::marginal density: I
''
m computing the posterior log marginal density (modified harmonic mean)... '
);
logdetSIGMA
=
log
(
det
(
SIGMA
));
...
...
matlab/model_comparison.m
View file @
440a0e46
...
...
@@ -81,9 +81,9 @@ for i=1:NumberOfModels
mstruct
.
oo_
=
oo
;
else
if
strcmpi
(
ModelNames
{
i
}(
end
-
3
:
end
),
'.mod'
)
||
strcmpi
(
ModelNames
{
i
}(
end
-
3
:
end
),
'.dyn'
)
mstruct
=
load
([
ModelNames
{
i
}(
1
:
end
-
4
)
'_results.mat'
],
'oo_'
);
mstruct
=
load
([
ModelNames
{
i
}(
1
:
end
-
4
)
filesep
'Output'
ModelNames
{
i
}(
1
:
end
-
4
)
'_results.mat'
],
'oo_'
);
else
mstruct
=
load
([
ModelNames
{
i
}
'_results.mat'
],
'oo_'
);
mstruct
=
load
([
ModelNames
{
i
}
filesep
'Output'
filesep
ModelNames
{
i
}
'_results.mat'
],
'oo_'
);
end
end
try
...
...
matlab/partial_information/dr1_PI.m
View file @
440a0e46
...
...
@@ -154,7 +154,7 @@ else
end
if
options_
.
debug
save
([
M_
.
fname
'_debug.mat'
],
'jacobia_'
)
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_debug.mat'
],
'jacobia_'
)
end
dr
=
set_state_space
(
dr
,
M_
,
options_
);
...
...
matlab/simult.m
View file @
440a0e46
...
...
@@ -66,7 +66,7 @@ order = DynareOptions.order;
replic
=
DynareOptions
.
simul_replic
;
if
replic
>
1
fname
=
[
DynareModel
.
fname
,
'
_simul
'
];
fname
=
[
DynareModel
.
dname
filesep
'
Output
'
DynareModel
.
fname
,
'
_simul
'
];
fh
=
fopen
(
fname
,
'
w
+
'
);
end
...
...
matlab/stochastic_solvers.m
View file @
440a0e46
...
...
@@ -128,7 +128,7 @@ elseif local_order == 2
if
~
isempty
(
infrow
)
fprintf
(
'\nSTOCHASTIC_SOLVER: The Hessian of the dynamic model contains Inf.\n'
)
fprintf
(
'STOCHASTIC_SOLVER: Try running model_diagnostics to find the source of the problem.\n'
)
save
([
M_
.
fname
'_debug.mat'
],
'hessian1'
)
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_debug.mat'
],
'hessian1'
)
end
end
if
~
isempty
(
infrow
)
...
...
@@ -140,7 +140,7 @@ elseif local_order == 2
if
~
isempty
(
nanrow
)
fprintf
(
'\nSTOCHASTIC_SOLVER: The Hessian of the dynamic model contains NaN.\n'
)
fprintf
(
'STOCHASTIC_SOLVER: Try running model_diagnostics to find the source of the problem.\n'
)
save
([
M_
.
fname
'_debug.mat'
],
'hessian1'
)
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_debug.mat'
],
'hessian1'
)
end
end
if
~
isempty
(
nanrow
)
...
...
@@ -155,7 +155,7 @@ if options_.debug
if
~
isempty
(
infrow
)
fprintf
(
'\nSTOCHASTIC_SOLVER: The Jacobian of the dynamic model contains Inf. The problem is associated with:\n\n'
)
display_problematic_vars_Jacobian
(
infrow
,
infcol
,
M_
,
dr
.
ys
,
'dynamic'
,
'STOCHASTIC_SOLVER: '
)
save
([
M_
.
fname
'_debug.mat'
],
'jacobia_'
)
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_debug.mat'
],
'jacobia_'
)
end
end
...
...
@@ -184,7 +184,7 @@ if options_.debug
if
~
isempty
(
nanrow
)
fprintf
(
'\nSTOCHASTIC_SOLVER: The Jacobian of the dynamic model contains NaN. The problem is associated with:\n\n'
)
display_problematic_vars_Jacobian
(
nanrow
,
nancol
,
M_
,
dr
.
ys
,
'dynamic'
,
'STOCHASTIC_SOLVER: '
)
save
([
M_
.
fname
'_debug.mat'
],
'jacobia_'
)
save
([
M_
.
dname
filesep
'Output'
filesep
M_
.
fname
'_debug.mat'
],
'jacobia_'
)
end
end
...
...
preprocessor
@
bb19d987
Compare
5cfe6303
...
bb19d987
Subproject commit
5cfe6303e26fcaeff204e6d2ca3988b169621f46
Subproject commit
bb19d98712f2599380dfc704f98b33531d7414de
tests/AIM/fs2000_b1L1L_AIM.mod
View file @
440a0e46
...
...
@@ -92,7 +92,7 @@ steady(nocheck);
stoch_simul
(
aim_solver
,
order
=
1
,
irf
=
0
);
benchmark
=
load
(
'fs2000_b1L1L_results'
);
benchmark
=
load
(
[
'fs2000_b1L1L'
filesep
'Output'
filesep
'fs2000_b1L1L_results'
]
);
threshold
=
1e-8
;
if
max
(
max
(
abs
(
benchmark
.
oo_
.
dr
.
ghx
-
oo_
.
dr
.
ghx
)
>
threshold
));
...
...
tests/AIM/fs2000x10L9_L_AIM.mod
View file @
440a0e46
...
...
@@ -76,7 +76,7 @@ check;
stoch_simul(aim_solver, order=1,irf=0);
benchmark = load('fs2000x10L9_L_results');
benchmark = load(
['fs2000x10L9_L' filesep 'Output' filesep
'fs2000x10L9_L_results'
]
);
threshold = 1e-8;
if max(max(abs(benchmark.oo_.dr.ghx-oo_.dr.ghx) > threshold));
...
...
tests/AIM/fs2000x10_L9_L_AIM.mod
View file @
440a0e46
...
...
@@ -57,7 +57,7 @@ steady;
stoch_simul(aim_solver, order=1,irf=0);
benchmark = load('fs2000x10_L9_L_results');
benchmark = load(
['fs2000x10_L9_L' filesep 'Output' filesep
'fs2000x10_L9_L_results'
]
);
threshold = 1e-8;
if max(max(abs(benchmark.oo_.dr.ghx-oo_.dr.ghx) > threshold));
...
...
tests/AIM/ls2003_2L0L_AIM.mod
View file @
440a0e46
...
...
@@ -45,7 +45,7 @@ end;
stoch_simul(aim_solver, order=1,irf=0);
benchmark = load('ls2003_2L0L_results');
benchmark = load(
['ls2003_2L0L' filesep 'Output' filesep
'ls2003_2L0L_results'
]
);
threshold = 1e-8;
if max(max(abs(benchmark.oo_.dr.ghx-oo_.dr.ghx) > threshold));
...
...
tests/AIM/ls2003_2L2L_AIM.mod
View file @
440a0e46
...
...
@@ -43,7 +43,7 @@ end;
stoch_simul(aim_solver, order=1,irf=0);
benchmark = load('ls2003_2L2L_results');
benchmark = load(
['ls2003_2L2L' filesep 'Output' filesep
'ls2003_2L2L_results'
]
);
threshold = 1e-8;
if max(max(abs(benchmark.oo_.dr.ghx-oo_.dr.ghx) > threshold));
...
...
tests/Makefile.am
View file @
440a0e46
...
...
@@ -1412,13 +1412,6 @@ clean-local:
rm
-f
$(
patsubst
%.trs, %.json,
$(O_TRS_FILES)
)
rm
-f
$(
patsubst
%.trs, %.json,
$(O_XFAIL_TRS_FILES)
)
rm
-f
$(patsubst
%.mod,
%_results.mat,
$(MODFILES))
rm
-f
$(patsubst
%.mod,
%_mode.mat,
$(MODFILES))
rm
-f
$(patsubst
%.mod,
%_mh_mode.mat,
$(MODFILES))
rm
-f
$(patsubst
%.mod,
%_mean.mat,
$(MODFILES))
rm
-f
$(patsubst
%.mod,
%_pindx.mat,
$(MODFILES))
rm
-f
$(patsubst
%.mod,
%_params.mat,
$(MODFILES))
rm
-f
$(patsubst
%.mod,
%_simul,
$(MODFILES))
rm
-f
$(patsubst
%.mod,
%.log,
$(MODFILES))
rm
-rf
$(patsubst
%.mod,
%,
$(MODFILES))
...
...
tests/analytic_derivatives/fs2000_analytic_derivation.mod
View file @
440a0e46
...
...
@@ -78,22 +78,22 @@ options_.solve_tolf = 1e-12;
estimation(order=1,mode_compute=9,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0,prior_trunc=0);
if (isoctave && user_has_octave_forge_package('optim', '1.6')) || (~isoctave && user_has_matlab_license('optimization_toolbox'))
estimation(order=1,mode_compute=1,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0
estimation(order=1,mode_compute=1,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0
%,optim = ('DerivativeCheck', 'on','FiniteDifferenceType','central')
);
estimation(order=1,mode_compute=3,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=101,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=3,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=101,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
end
estimation(order=1,mode_compute=5,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=4,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=4,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=5,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=4,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=4,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
options_.debug=1;
estimation(order=1,mode_compute=0,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
estimation(order=1,mode_compute=0,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
fval_ML_1=oo_.likelihood_at_initial_parameters;
estimation(order=1,mode_compute=0,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
estimation(order=1,mode_compute=0,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
fval_ML_2=oo_.likelihood_at_initial_parameters;
options_.analytic_derivation=0;
estimation(order=1,mode_compute=0,mode_file=fs2000_analytic_derivation_mode,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
estimation(order=1,mode_compute=0,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
fval_ML_3=oo_.likelihood_at_initial_parameters;
if abs(fval_ML_1-fval_ML_2)>1e-5 || abs(fval_ML_1-fval_ML_3)>1e-5
...
...
@@ -111,22 +111,22 @@ end;
estimation(order=1,mode_compute=9,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0,prior_trunc=0);
if (isoctave && user_has_octave_forge_package('optim', '1.6')) || (~isoctave && user_has_matlab_license('optimization_toolbox'))
estimation(order=1,mode_compute=1,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0
estimation(order=1,mode_compute=1,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0
%,optim = ('DerivativeCheck', 'on','FiniteDifferenceType','central')
);
estimation(order=1,mode_compute=3,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=101,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=3,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=101,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
end
estimation(order=1,mode_compute=5,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=4,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=4,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=5,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=4,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
estimation(order=1,mode_compute=4,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,mh_nblocks=2,mh_jscale=0.8,plot_priors=0);
options_.debug=1;
estimation(order=1,mode_compute=0,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
estimation(order=1,mode_compute=0,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
fval_Bayes_1=oo_.likelihood_at_initial_parameters;
estimation(order=1,mode_compute=0,mode_file=fs2000_analytic_derivation_mode,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
estimation(order=1,mode_compute=0,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,analytic_derivation,kalman_algo=2,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
fval_Bayes_2=oo_.likelihood_at_initial_parameters;
options_.analytic_derivation=0;
estimation(order=1,mode_compute=0,mode_file=fs2000_analytic_derivation_mode,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
estimation(order=1,mode_compute=0,mode_file=
'fs2000_analytic_derivation/Output/
fs2000_analytic_derivation_mode
'
,kalman_algo=1,datafile=my_data,nobs=192,mh_replic=0,plot_priors=0);
fval_Bayes_3=oo_.likelihood_at_initial_parameters;
if abs(fval_Bayes_1-fval_Bayes_2)>1e-5 || abs(fval_Bayes_1-fval_Bayes_3)>1e-5
...
...
tests/block_bytecode/lola_solve_one_boundary_mfs1.mod
View file @
440a0e46
...
...
@@ -5,7 +5,7 @@
@#define mfs = 1
@#include "lola_common.inc"
mfs0=load('lola_solve_one_boundary_results');
mfs0=load(
['lola_solve_one_boundary' filesep 'Output' filesep
'lola_solve_one_boundary_results'
]
);
if max(max(oo_.endo_simul-mfs0.oo_.endo_simul)) > options_.dynatol.x
error('Inconsistency with mfs=0')
...
...
Prev
1
2
3
4
5
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment