我遇到的熊猫属性错误:0.24.2
expwighted_avg = pd.ewma(ts_log, halflife=12)
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
<ipython-input-67-cbd5d537822b> in <module>()
----> 1 expwighted_avg = pd.ewma(ts_log, halflife=12)
AttributeError: module 'pandas' has no attribute 'ewma'
答案 0 :(得分:0)
对我来说,现在可以正常工作并且代码可以成功运行
expwighted_avg = ts_log.ewm(halflife=12).mean()