Calculating Strategy Orders on a Real-time/Delayed Basis
During market hours, the TradeStation network provides price data trade-by-trade. As each trade is received, TradeStation calculates whether or not the entry or exit criteria of an applied trading strategy are triggered by that trade price. If a trade price is received that matches the criteria of the strategy, TradeStation issues a signal at the exact moment the trade price is received.
It is possible to both enter and exit the market on the same bar. TradeStation handles both entries and exits in the order in which the trade prices are received. If the exit signal of a trading strategy is triggered first in a bar in which both the entry and exit criteria of a strategy are met, TradeStation handles the exit criteria in the following ways:
- If you do not have an open position and a trade price triggers the exit criteria of your strategy first and then a later trade price triggers the entry criteria, TradeStation ignores the exit criteria (because at the time there is no open position to exit) but issues the entry signal to open a position.
- If you do have an open position and on the same time-based bar a trade price triggers the exit criteria of your strategy and then a trade price triggers the entry criteria of your strategy, TradeStation shows the open position as having been liquidated due to the exit criteria, then would show a new open position based on the entry signal.
TradeStation can calculate the entry and exit criteria of your trading strategy with great precision and enter and exit the market based on exactly what is happening in the market when one or more of the criteria of your strategy are met.