For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/

Intra minute trade with OHLC



  • Hello, we would like to confirm expected behavior of backtrader to make sure we have not made a mistake. We are backtesting bracket orders with 1-min aggregation prices. If a bracket order is triggered within the same minute as the entry minute then we observe the exit price is the open of the next min. Is this expected behavior?

    Background: We are confused because we see a different behavior when the bracket order is triggered after the first minute lapses. In this case the exit price_out matches the specified bracket order price not the open of the next min. I believe the behaviors should be the same. We will appreciate any clarification. We are using the trade analyzer to get the price_in and price_out values.




Log in to reply
 

});