From: Lucas campos on 28 May 2010 13:12 Hi there, I need some help in fitting data to a curve. I have a curve (x,y) but I do not have the equation that generates that curve. I have only a set of points x,y. What I need is some function or strategy that will give me an approximated 'y' in function of any given x. Could someone send me suggestions? Thanks a lot
From: Matt J on 28 May 2010 13:19 "Lucas campos" <campos.lucas(a)gmail.com> wrote in message <htothc$sie$1(a)fred.mathworks.com>... > What I need is some function or strategy that will give me an approximated 'y' in function of any given x. > > Could someone send me suggestions? ============= Buy the Curve Fit toolbox? Or search "curve fit" on the FEX for many options.
From: Walter Roberson on 28 May 2010 13:33 Lucas campos wrote: > I need some help in fitting data to a curve. > > I have a curve (x,y) but I do not have the equation that generates that > curve. I have only a set of points x,y. > > What I need is some function or strategy that will give me an > approximated 'y' in function of any given x. polyfit() will give you a result no less "correct" as any other in this situation. As I wrote in another thread yesterday, "There is not (and cannot be) a unique or meaningful answer unless you already know the form the formula should take. Think of your known X, Y, and Z as fixed physical points and think of there being elastic sheets connecting all of the points to their neighbours: you can pinch or stretch any of the elastic sheets an infinite number of ways, and each different way represents a different possible formula that completely explains the data. If you do not have some knowledge ahead of time that constrains the possibilities, you have no way of saying that any of the infinite number of formula are more correct than any of the others, and the probability that you will hit upon the correct formula would be 0."
From: Steven Lord on 28 May 2010 13:33 "Lucas campos" <campos.lucas(a)gmail.com> wrote in message news:htothc$sie$1(a)fred.mathworks.com... > Hi there, > > I need some help in fitting data to a curve. > > I have a curve (x,y) but I do not have the equation that generates that > curve. I have only a set of points x,y. > > What I need is some function or strategy that will give me an approximated > 'y' in function of any given x. > > Could someone send me suggestions? Do you want the actual equation or do you just want to interpolate for a given y? For the former, look at Curve Fitting Toolbox or the other functions listed in this document: http://www.mathworks.com/support/tech-notes/1500/1508.html For the latter, look at INTERP1. -- Steve Lord slord(a)mathworks.com comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ To contact Technical Support use the Contact Us link on http://www.mathworks.com
|
Pages: 1 Prev: Global Variables/Passing Data Using GUIDE Next: Global Variables/Passing Data Using GUIDE |