>>> s = pd.Series([5, 5, 6, 7, 5, 5, 5])
>>> s.rolling(3).std()
2 module 'pandas' has no attribute 'ewma'
使用series.ewm(span)
3 module 'pandas' has no attribute 'rolling_mean'
#rolmean = pd.rolling_mean(timeseries, window=12) #对size个数据进行移动平均
rolmean = timeseries.rolling(window=12).mean() #对size个数据进行移动平均
module 'pandas' has no attribute 'rolling_std'
猜你喜欢
转载自blog.csdn.net/tony2278/article/details/86009780
今日推荐
周排行