Ejemplo n.º 1
0
 def __init__(self, volumeLimit=0.25):
     super(DefaultStrategy, self).__init__()
     self.__volumeLeft = {}
     self.__volumeUsed = {}
     self.setVolumeLimit(volumeLimit)
     self.setSlippageModel(slippage.NoSlippage())
Ejemplo n.º 2
0
 def setUp(self):
     BaseTestCase.setUp(self)
     self.slippage = slippage.NoSlippage()
     self.barsBuilder = broker_backtesting_test.BarsBuilder(
         BaseTestCase.TestInstrument, bar.Frequency.DAY)
Ejemplo n.º 3
0
 def setUp(self):
     super(NoSlippageTestCase, self).setUp()
     self.slippage = slippage.NoSlippage()
     self.barsBuilder = broker_backtesting_test.BarsBuilder(INSTRUMENT, bar.Frequency.DAY)