当前位置: 首页>>代码示例>>Python>>正文


Python test_algorithms.TestOrderInstantAlgorithm类代码示例

本文整理汇总了Python中zipline.test_algorithms.TestOrderInstantAlgorithm的典型用法代码示例。如果您正苦于以下问题:Python TestOrderInstantAlgorithm类的具体用法?Python TestOrderInstantAlgorithm怎么用?Python TestOrderInstantAlgorithm使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了TestOrderInstantAlgorithm类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: test_minute_data

 def test_minute_data(self):
     source = RandomWalkSource(freq='minute',
                               start=pd.Timestamp('2000-1-3',
                                                  tz='UTC'),
                               end=pd.Timestamp('2000-1-4',
                                                tz='UTC'))
     self.sim_params.data_frequency = 'minute'
     algo = TestOrderInstantAlgorithm(sim_params=self.sim_params,
                                      instant_fill=True)
     algo.run(source)
开发者ID:erain,项目名称:zipline,代码行数:10,代码来源:test_algorithm.py

示例2: test_minute_data

 def test_minute_data(self):
     source = RandomWalkSource(
         freq="minute", start=pd.Timestamp("2000-1-1", tz="UTC"), end=pd.Timestamp("2000-1-1", tz="UTC")
     )
     algo = TestOrderInstantAlgorithm(sim_params=self.sim_params, data_frequency="minute", instant_fill=True)
     algo.run(source)
开发者ID:ChrisBg,项目名称:zipline,代码行数:6,代码来源:test_algorithm.py

示例3: test_order_instant

    def test_order_instant(self):
        algo = TestOrderInstantAlgorithm(sim_params=self.sim_params, data_frequency="daily", instant_fill=True)

        algo.run(self.df)
开发者ID:ChrisBg,项目名称:zipline,代码行数:4,代码来源:test_algorithm.py

示例4: test_order_instant

    def test_order_instant(self):
        algo = TestOrderInstantAlgorithm(sim_params=self.sim_params,
                                         instant_fill=True)

        algo.run(self.df)
开发者ID:erain,项目名称:zipline,代码行数:5,代码来源:test_algorithm.py


注:本文中的zipline.test_algorithms.TestOrderInstantAlgorithm类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。