What is the best way to calculate the max. draw down for an open position?
Say I have an open position,and it started to move against me , I would like to close at a certain loss (absolute of percentage wise), can anyone guide me as to how to do this in backtrader ?
@trade-prophet just issue the stop order, and position will be closed at that level.
or is there an internal mechanism for it in bt ?
@trade-prophet stop order is always the same order, doesn't matter if you open position or close. If you are in the long position, for example, you need to calculate price level lower than current price and issue stop order at this level As soon as price will cross the level from above, stop order will be executed.
So,as soon as the order is executed on notify_order - issue the reverse stop order ,right ?
@trade-prophet as soon as order executed position will be closed. Why it should issue reversed stop order?
@trade-prophet notify_order treats stop orders as any other order, it will be marked as executed with all related data as execution price etc established.
Thank you very much for all your help, much appreciated!