Nonlinear least square regression

2 次查看(过去 30 天)
ameen
ameen 2013-5-27
i have (x , y) data
the function between x and y is y = 0.392* (1 - (x / b1) .^ b2
i want to use nonlinear least square regression to obtain the values of b1 and b2
can any one help me with the structure of the Matlab program
thanks in advance
  1 个评论
Matt J
Matt J 2013-5-27
编辑:Matt J 2013-5-27
You're missing a parenthesis ')' in your regression model. It's important for us to know where it should go.

请先登录,再进行评论。

回答(1 个)

the cyclist
the cyclist 2013-5-27
If you have the Statistics Toolbox, then you can use the nlinfit() function.
Type
doc nlinfit
in the interface, or see this page for details: http://www.mathworks.com/help/stats/nlinfit.html
  8 个评论
ameen
ameen 2013-5-27
Thank you very much Matt
so the problem is with my data ??
Matt J
Matt J 2013-5-27
编辑:Matt J 2013-5-27
Or your model. Maybe you should be fitting
y=x(1)*exp(-x(2)*t)

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Descriptive Statistics 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by