diff --git a/backtrader/analyzers/pyfolio.py b/backtrader/analyzers/pyfolio.py index d15bc9d04..0162d8df3 100644 --- a/backtrader/analyzers/pyfolio.py +++ b/backtrader/analyzers/pyfolio.py @@ -127,7 +127,7 @@ def get_pf_items(self): # # Positions pss = self.rets['positions'] - ps = [[k] + v[-2:] for k, v in iteritems(pss)] + ps = [[k] + v[:] for k, v in iteritems(pss)] cols = ps.pop(0) # headers are in the first entry positions = DF.from_records(ps, index=cols[0], columns=cols) positions.index = pandas.to_datetime(positions.index)