TST: Update talib example for compatibility with multiple sids.

To support mulitple sids the TALib transforms now return a dict,
instead of a float. Accordingly, the TALib example script now needs
to index into the transform result.
This commit is contained in:
Eddie Hebert
2013-07-10 15:37:03 -04:00
parent eac882b773
commit 5758f885c5
+2 -2
View File
@@ -63,8 +63,8 @@ class DualEMATaLib(TradingAlgorithm):
self.sell = True
self.record(AAPL=data['AAPL'].price,
short_ema=self.short_ema,
long_ema=self.long_ema,
short_ema=self.short_ema['AAPL'],
long_ema=self.long_ema['AAPL'],
buy=self.buy,
sell=self.sell)