MCPcopy Create free account
hub / github.com/quantopian/zipline / default_initialize

Method default_initialize

tests/test_algorithm.py:3757–3768  ·  view source on GitHub ↗

Initialize function shared between test algos.

(self)

Source from the content-addressed store, hash-verified

3755 return self.daily_data[asset.sid].loc[asset.end_date].close
3756
3757 def default_initialize(self):
3758 """
3759 Initialize function shared between test algos.
3760 """
3761 def initialize(context):
3762 context.ordered = False
3763 context.set_commission(PerShare(0, 0))
3764 context.set_slippage(FixedSlippage(spread=0))
3765 context.num_positions = []
3766 context.cash = []
3767
3768 return initialize
3769
3770 def default_handle_data(self, assets, order_size):
3771 """

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected