In the following code snippet, I get the error: pandas does not have the attribute ewma. I can see it the documentation. Any ideas?
import pandas as pd
class BetaAlgorithm(QCAlgorithm):
def Initialize(self):
....
def Rebalance(self):
# Fetch the historical data to perform the linear regression
history = self.History(
self.symbols,
self.lookback,
Resolution.Daily).close.unstack(level=0)
prices = pd.ewma(history, span = self.lookback).as_matrix(self.symbols)
To unlock posting to the community forums please complete at least 30% of Boot Camp.
You can continue your Boot Camp training progress from the terminal. We hope to see you in the community soon!