I want to understand the behaviour of market order
When is market order executed ?
In the same bar OR in the next bar ?
if I comare this with real time market , market order is executed (attempted) in the current bar itself
I would appreciate if there are examples for different order types (I mean the raw order)
Thanks
Prasanna
No orders, in realtime or otherwise, is executed at the same time of the order submission. It is done in the next order matching cycle. In real trading, the order matching cycle can trigger within microsecods. In simulation, the lag depends on the granularity of data - either the next tick or the next bar. Blueshift uses (minute-level) bar data. The market order on Blueshift backtesting is eligible for execution from the next bar (next minute). The actual execution depends on the order size and the slippage model (see doc for details). Orders are never executed on the same bar to protect against look-ahead bias.
I think the minute level data should be enogranular enough for my use case
Thanks
Prasanna