User`s guide

fit
4-102
4fit
Purpose Fit data using a library or custom model, a smoothing spline, or an interpolant
Syntax fresult = fit(xdata,ydata,'ltype')
fresult = fit(xdata,ydata,'ltype','PropertyName',PropertyValue,…)
fresult = fit(xdata,ydata,'ltype',opts)
fresult = fit(xdata,ydata,'ltype',...,'problem',values)
fresult = fit(xdata,ydata,ftype,...)
[fresult,gof] = fit(…)
[fresult,gof,output] = fit(…)
Arguments
Description
fresult = fit(xdata,ydata,'ltype') fits the data specified by xdata and
ydata to the library model, interpolant, or smoothing spline specified by ltype.
The fit result is returned to
fresult. You can display the library fit type names
with the
cflibhelp function. xdata and ydata cannot contain Infs or NaNs.
Additionally, only the real part of a complex value is used.
xdata A column vector of predictor data.
ydata A column vector of response data.
'ltype' The name of a library model, spline, or interpolant.
'PropertyName' The name of a fit options property.
PropertyValue A valid value for PropertyName.
opts A fit options object.
'problem' Specify problem parameters.
values A cell array of problem parameter values.
ftype A fit type object.
fresult The fit result object.
gof Goodness of fit statistics.
output A structure containing information that is associated with
the fitting procedure.