I have a few rather basic questions about the way NT handles orders in real life trading.
Suppose I use the following code in my strategy:
if( condition1 ) { EnterLong( 10 ); }
if( condition2 ) { EnterShort( 10 ); }
if( condition3 ) { ExitLong( 10 ); }
if( condition4 ) { ExitShort( 10 ); }
1) Suppose that condition1..4 take a long time to evaluate (and/or PC is slow) and a new pricetick comes in when still in the middle of evaluating these four statements. Are all conditions then still evaluated using the same 'tick' ?
2) If yes, is this next tick qeued and then executed on all four conditions with some delay? Or is the tick dropped? Or...?
3) What would happen in an extreme case when the PC can really not keep up? Would it drop ticks or would it qeue them until it runs out of buffer, or....?
Of course I understand I need a decent PC that is fast enough for the scripts that I'm running. The questions above are just to understand how NT handles these conditions.
4) Suppose condition1, 2 and 3 become true at the same tick. Is my understanding correct that NT will only send one order to my broker for going short 10 contracts? i.e. NT will cancel the enterlong and exitlong against eachother?
5) Suppose condition1 is true during tick1. NT sends an order to my broker to go long 10 contracts. However, only 3 of them are filled. Then the next tick comes in, and on this tick condition1 becomes invalid. Will NT then automatically cancel the order for the remaining 7 contracts or will this order remain in place?
6) Suppose condition1 is true during tick1. NT sends an order to my broker to go long 10 contracts. However, only 3 of them are filled. Then the next tick comes in, and on this tick condition2 becomes valid. How will NT handle this? Will I end up with 7 contracts short or 10 contracts short?
Thanks
Comment