Why cannot I obtain Levenberg-Marquardt as the default Algorithm for 'fit'?
1 view (last 30 days)
Show older comments
MathWorks Support Team
on 7 Jul 2017
Edited: MathWorks Support Team
on 1 Mar 2021
"Input Arguments > Name-Value Pair Arguments > Nonlinear Least-Squares Options > Algoritm"
the default is 'Levenberg-Marquardt'.
However 'Trust-Region' is displayed by 'fitoptions' instead.
Why is this happening ('Levenberg-Marquardt' is being changed to 'Trust-Region')?
>> ft = fittype('10^(a*x+b)');
ans = fit(X,Y,ft,'StartPoint',[p(1),p(2)]);
>> fitoptions(ft)
Normalize: 'off'
Exclude: []
Weights: []
Method: 'NonlinearLeastSquares'
Robust: 'Off'
StartPoint: [1x0 double]
Lower: [1x0 double]
Upper: [1x0 double]
Algorithm: 'Trust-Region'
DiffMinChange: 1.0000e-08
DiffMaxChange: 0.1000
Display: 'Notify'
MaxFunEvals: 600
MaxIter: 400
TolFun: 1.0000e-06
TolX: 1.0000e-06
Accepted Answer
MathWorks Support Team
on 1 Mar 2021
Edited: MathWorks Support Team
on 26 Feb 2021
This is a documentation bug.
The default algorithm for 'fit' is 'Trust-Region' since 2002.
0 Comments
More Answers (0)
See Also
Categories
Find more on Interpolation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!