Octave compatibility fix: the 3rd output argument to fminsearch was added in Octave 4.4
parent
873685e7e6
commit
e413696277
|
@ -353,9 +353,9 @@ switch minimizer_algorithm
|
||||||
[opt_par_values,fval,exitflag] = fminsearch(objective_function,start_par_value,optim_options,varargin{:});
|
[opt_par_values,fval,exitflag] = fminsearch(objective_function,start_par_value,optim_options,varargin{:});
|
||||||
else
|
else
|
||||||
% Under Octave, use a wrapper, since fminsearch() does not have a
|
% Under Octave, use a wrapper, since fminsearch() does not have a
|
||||||
% 4th arg, and only has two output args
|
% 4th arg.
|
||||||
func = @(x) objective_function(x,varargin{:});
|
func = @(x) objective_function(x,varargin{:});
|
||||||
[opt_par_values,fval] = fminsearch(func,start_par_value,optim_options);
|
[opt_par_values,fval,exitflag] = fminsearch(func,start_par_value,optim_options);
|
||||||
end
|
end
|
||||||
case 8
|
case 8
|
||||||
% Dynare implementation of the simplex algorithm.
|
% Dynare implementation of the simplex algorithm.
|
||||||
|
|
Loading…
Reference in New Issue