I am having an error from running a simple alphalens code below. Could anyone help why I got this error. Thanks
from quantopian.pipeline.data import factset
from quantopian.pipeline import Pipeline
from quantopian.research import run_pipeline
from quantopian.pipeline.factors import CustomFactor, SimpleMovingAverage
from quantopian.pipeline.filters import QTradableStocksUS
from alphalens.tears import create_information_tear_sheet
from alphalens.utils import get_clean_factor_and_forward_returns
from quantopian.pipeline.data import morningstar
def make_pipeline():
ev_ebitda = factset.Fundamentals.entrpr_val_ebitda_oper_af
factor_to_analyze = ev_ebitda
return Pipeline(
columns = {'factor_to_analyze': factor_to_analyze},
screen = QTradableStocksUS() & factor_to_analyze.notnull()
)
pipeline_output = run_pipeline(make_pipeline(), '2015-1-1', '2016-1-1')
pricing_data = get_pricing(pipeline_output.index.levels[1], '2015-1-1', '2018-2-1', fields='open_price')
new_factor_data = get_clean_factor_and_forward_returns(pipeline_output, pricing_data)
create_information_tear_sheet(new_factor_data)