Main Content

平滑

使用平滑样条和局部回归进行拟合,使用移动平均值和其他滤波器对数据进行平滑处理

平滑是一种减少数据集中噪声的方法。Curve Fitting Toolbox™ 允许您使用移动平均值、萨维茨基-戈雷滤波器和 Lowess 模型等方法或通过拟合平滑样条来对数据进行平滑处理。

使用曲线拟合器或在命令行中使用 smooth 函数以交互方式对数据进行平滑处理。有关如何对数据进行平滑处理的示例,请参阅Fit Smooth Surfaces to Investigate Fuel Efficiency

App

曲线拟合器对数据进行曲线和曲面拟合

函数

datastatsData statistics
excludedataExclude data from fit
fit对数据进行曲线或曲面拟合
fittype曲线和曲面拟合的拟合类型
fitoptions创建或修改拟合选项对象
getGet fit options structure property names and values
setAssign values in fit options structure
smooth平滑响应数据
prepareCurveData 为曲线拟合准备数据输入
prepareSurfaceDataPrepare data inputs for surface fitting

主题

  • Smoothing Splines

    Fit smoothing splines in the Curve Fitter app or with the fit function to create a smooth curve through data and specify the smoothness.

  • Lowess Smoothing

    Fit smooth surfaces to your data in the Curve Fitter app or with the fit function using Lowess models.

  • Filtering and Smoothing Data

    Use the smooth function to smooth response data, using methods for moving average, Savitzky-Golay filters, and local regression with and without weights and robustness (lowess, loess, rlowess and rloess).

  • Fit Smooth Surfaces to Investigate Fuel Efficiency

    This example shows how to use Curve Fitting Toolbox™ to fit a response surface to some automotive data to investigate fuel efficiency.

  • Nonparametric Fitting

    Perform nonparametric fitting to create smooth curves or surfaces through your data with interpolants and smoothing splines.