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
Dóra Kocsis
dynare
Commits
5c883389
Commit
5c883389
authored
Jan 07, 2013
by
Sébastien Villemot
Browse files
Fix mode_compute=3 under Octave
parent
8c7e3d46
Changes
1
Hide whitespace changes
Inline
Side-by-side
matlab/dynare_estimation_1.m
View file @
5c883389
...
...
@@ -221,7 +221,14 @@ if ~isequal(options_.mode_compute,0) && ~options_.mh_posterior_mode_estimation
if
options_
.
analytic_derivation
,
optim_options
=
optimset
(
optim_options
,
'GradObj'
,
'on'
);
end
[
xparam1
,
fval
,
exitflag
]
=
fminunc
(
objective_function
,
xparam1
,
optim_options
,
dataset_
,
options_
,
M_
,
estim_params_
,
bayestopt_
,
oo_
);
if
~
exist
(
'OCTAVE_VERSION'
)
[
xparam1
,
fval
,
exitflag
]
=
fminunc
(
objective_function
,
xparam1
,
optim_options
,
dataset_
,
options_
,
M_
,
estim_params_
,
bayestopt_
,
oo_
);
else
% Under Octave, use a wrapper, since fminunc() does not have a 4th arg
func
=
@
(
x
)
objective_function
(
x
,
dataset_
,
options_
,
M_
,
estim_params_
,
bayestopt_
,
oo_
);
[
xparam1
,
fval
,
exitflag
]
=
fminunc
(
func
,
xparam1
,
optim_options
);
end
case
4
H0
=
1e-4
*
eye
(
nx
);
crit
=
1e-7
;
...
...
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