Access to trade information #735
-
Hello, I am trying to collect the data of each trade within the backtesting results. Reading the documentation, I have seen that the trades have a "pl_pct" attribute that reflects the profit or loss in percentage of each trade. I'm right? However, when I try to collect the trade data treating it as a dataframe: stats[_trade] I don't find the column referring to that property. How can I find that type of data (pl, pl_pct...) of each trade once the backtesting is done? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
backtesting.py/backtesting/_stats.py Line 65 in 65f54f6 |
Beta Was this translation helpful? Give feedback.
Trade.pl_pct
is matched byReturnPct
in trade data dataframe:backtesting.py/backtesting/_stats.py
Line 65 in 65f54f6