Quantopian's community platform is shutting down. Please read this post for more information and download your code.
Back to Community
Basic help - What does quantopian.algorithm do?

In the template algorithm that appears when you make a new algorithm, it has the following:

import quantopian.algorithm as algo
from quantopian.pipeline import Pipeline
from quantopian.pipeline.data.builtin import USEquityPricing
from quantopian.pipeline.filters import QTradableStocksUS
def initialize(context):
"""
Called once at the start of the algorithm.
"""
# Rebalance every day, 1 hour after market open.
algo.schedule_function(
rebalance,
algo.date_rules.every_day(),
algo.time_rules.market_open(hours=1),
)

quantopian.algorithm isn't described in the api reference. Why is algo.schedule_function used instead of just schedule_function? Also, why isn't something like this included in the API doc?

1 response