注册 登录  
 加关注
   显示下一条  |  关闭
温馨提示!由于新浪微博认证机制调整,您的新浪微博帐号绑定已过期,请重新绑定!立即重新绑定新浪微博》  |  关闭

数据挖掘

学习数据挖掘

 
 
 

日志

 
 

Matlab SMooth 函数  

2013-05-05 21:30:06|  分类: Matlab |  标签: |举报 |字号 订阅

  下载LOFTER 我的照片书  |

Matlab  SMooth 函数 - 小坏 - Do  What
 Matlab  SMooth 函数 - 小坏 - Do  What
 Matlab  SMooth 函数 - 小坏 - Do  What
 Matlab  SMooth 函数 - 小坏 - Do  What
  smooth  Smooth data.
    Z = smooth(Y) smooths data Y using a 5-point moving average.
 
    Z = smooth(Y,SPAN) smooths data Y using SPAN as the number of points used
    to compute each element of Z.
 
    Z = smooth(Y,SPAN,METHOD) smooths data Y with specified METHOD. The
    available methods are:
 
            'moving'   - Moving average (default)
            'lowess'   - Lowess (linear fit)
            'loess'    - Loess (quadratic fit)
            'sgolay'   - Savitzky-Golay
            'rlowess'  - Robust Lowess (linear fit)
            'rloess'   - Robust Loess (quadratic fit)
 
    Z = smooth(Y,METHOD) uses the default SPAN 5.
 
    Z = smooth(Y,SPAN,'sgolay',DEGREE) and Z = smooth(Y,'sgolay',DEGREE)
    additionally specify the degree of the polynomial to be used in the
    Savitzky-Golay method. The default DEGREE is 2. DEGREE must be smaller
    than SPAN.
 
    Z = smooth(X,Y,...) additionally specifies the X coordinates.  If X is
    not provided, methods that require X coordinates assume X = 1:N, where
    N is the length of Y.
 
    Notes:
    1. When X is given and X is not uniformly distributed, the default method
    is 'lowess'.  The 'moving' method is not recommended.
 
    2. For the 'moving' and 'sgolay' methods, SPAN must be odd.
    If an even SPAN is specified, it is reduced by 1.
 
    3. If SPAN is greater than the length of Y, it is reduced to the
    length of Y.
 
    4. In the case of (robust) lowess and (robust) loess, it is also
    possible to specify the SPAN as a percentage of the total number
    of data points. When SPAN is less than or equal to 1, it is
    treated as a percentage.
 
    For example:
 
    Z = smooth(Y) uses the moving average method with span 5 and
    X=1:length(Y).
 
    Z = smooth(Y,7) uses the moving average method with span 7 and
    X=1:length(Y).
 
    Z = smooth(Y,'sgolay') uses the Savitzky-Golay method with DEGREE=2,
    SPAN = 5, X = 1:length(Y).
 
    Z = smooth(X,Y,'lowess') uses the lowess method with SPAN=5.
 
    Z = smooth(X,Y,SPAN,'rloess') uses the robust loess method.
 
    Z = smooth(X,Y) where X is unevenly distributed uses the
    'lowess' method with span 5.
 
    Z = smooth(X,Y,8,'sgolay') uses the Savitzky-Golay method with
    span 7 (8 is reduced by 1 to make it odd).
 
    Z = smooth(X,Y,0.3,'loess') uses the loess method where span is
    30% of the data, i.e. span = ceil(0.3*length(Y)).
  评论这张
 
阅读(34706)| 评论(2)
推荐 转载

历史上的今天

评论

<#--最新日志,群博日志--> <#--推荐日志--> <#--引用记录--> <#--博主推荐--> <#--随机阅读--> <#--首页推荐--> <#--历史上的今天--> <#--被推荐日志--> <#--上一篇,下一篇--> <#-- 热度 --> <#-- 网易新闻广告 --> <#--右边模块结构--> <#--评论模块结构--> <#--引用模块结构--> <#--博主发起的投票-->
 
 
 
 
 
 
 
 
 
 
 
 
 
 

页脚

网易公司版权所有 ©1997-2017