mirror of
https://github.com/wassname/catalyst.git
synced 2026-07-07 10:22:27 +08:00
MAINT: Use a for loop for main algorithm run loop instead of list
So that stepping through a debugger is a little easier, with respect to having easy access to the algorithm object, and seeing which step in `self.gen` the interpreter is currently at.
This commit is contained in:
@@ -298,7 +298,9 @@ class TradingAlgorithm(object):
|
||||
|
||||
# loop through simulated_trading, each iteration returns a
|
||||
# perf dictionary
|
||||
perfs = list(self.gen)
|
||||
perfs = []
|
||||
for perf in self.gen:
|
||||
perfs.append(perf)
|
||||
|
||||
# convert perf dict to pandas dataframe
|
||||
daily_stats = self._create_daily_stats(perfs)
|
||||
|
||||
Reference in New Issue
Block a user