With strategy analyzer, the order won't be submitted until the open of the next bar, even with historical fill resolution set to tick.
During live/market replay, the order will be triggered instantly as I would hope, but then it keeps closing position and then resubmitting until finally your sim account is drained to the point that you don't have enough margin. I tested this on ES, CL, etc.
I don't want the script to keep submitting orders to go long if my market position is already long. Same applies for being short. Any help with the code logic will be greatly appreciated.
Comment