Define multiple starting points for two-exponential curve fitting (Curve Fitting Toolbox)

2 次查看(过去 30 天)
Hi,
I have a set of data on which I need to use the two-exponential decay model 'exp2' from the Curve Fitting Toolbox. When I attempted to call the "fit" function ( f=fit(xCol,yCol,'exp2','StartPoint',[maxX,maxY])), MATLAB told me I needed 4 starting points for this model. What is the proper syntax for specifying these? I tried:
f=fit(xCol,yCol,'exp2','StartPoint',[maxX1,maxY1,maxX2,maxY2,maxX3,maxY3,maxX4,maxY4])), but MATLAB told me I had too many start points.
Thanks in advance!

采纳的回答

Adam Danz
Adam Danz 2018-7-26
If you're fitting a 2-term exponential model such as
f2(x) = a*exp(b*x) + c*exp(d*x)
you'll need 4 starting points (a,b,c,d). In your examples above, you provide 2 and 8 starting points. Your formatting them correctly into a vector but you just need 4 of them.
For more info, see the section " Fit a Two-Term Exponential Model ".

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Linear and Nonlinear Regression 的更多信息

产品


版本

R2015b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by