Path: news.mathworks.com!not-for-mail
From: "John D'Errico" <woodchips@rochester.rr.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Non-polynomial Curve Fit problem
Date: Thu, 16 Apr 2009 20:07:02 +0000 (UTC)
Organization: John D'Errico (1-3LEW5R)
Lines: 19
Message-ID: <gs8356$r7v$1@fred.mathworks.com>
References: <gs7tqh$3oc$1@fred.mathworks.com>
Reply-To: "John D'Errico" <woodchips@rochester.rr.com>
NNTP-Posting-Host: webapp-05-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1239912422 27903 172.30.248.35 (16 Apr 2009 20:07:02 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 16 Apr 2009 20:07:02 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 869215
Xref: news.mathworks.com comp.soft-sys.matlab:533319


"lan " <amoyjiajia@hotmail.com> wrote in message <gs7tqh$3oc$1@fred.mathworks.com>...
> Below is my figure data:
> 
> x=[-28.87 -27.35 -18.67 -22.42 -34.53 -52.73 -60.72 -68.06 -87.41 -94.16]';
> y=[-11.56   -5.57  3.26    7.15    7.69    5.82   7.99   10.45    2.70         0];
> plot(x,y,'ro-');
> grid;
> axis equal;
> 
> I have tried the polyfit but not successful, which changed my data order firstly.
> I want to make a curve fit which can keep the shape of the path in above figure. Especially in the right side where there is a ear or shoulder shape.
> 
> Thanks,

I would suggest a simple model:

  yhat = mean(y)

John