Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Cancelled stop/profit target orders

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Cancelled stop/profit target orders

    Dear Sir/Madam

    At today's US stock open, I was autotrading four instruments:

    "Instrument 1" / strategy "A"
    "Instrument 2" / strategy "B1"
    "Instrument 3" / strategy "B2"
    "Instrument 4" / strategy "B3"

    Strategies A, B1, B2 and B3 are all separate strategies that I run separately on different charts open on NT.

    All four intrument/strategy combinations placed orders at 09:30:16, and were filled by 09:30:29.

    At 09:36:30, "Instrument 2"/B1 hit its profit target and exited.

    Unexpectedly, it also looks like the stop/profit target orders associated with "Instrument 1"/A and "Instrument 4"/B3 were cancelled (by NT?) approximately 1 second later (but not the stop/profit target orders for "Instrument 3"/B2).

    I don't understand why? Can you help shed any light on this?

    Thanks
    = = = = = = =

    On Mon, Jan 11, 2010 at 12:56 PM, NinjaTrader Customer Service <[email protected]> wrote:
    Hello,

    Thank you for your note.


    I checked your log file and it displays the two profit targets in question were manually cancelled.


    11/01/2010 9:36:31|1|32|Order='1f03701:0299/XXXXXXXX' Name='Profit target' New State=PendingCancel Instrument='Instrument 1' Action=BuyToCover Limit price=XX,57 Stop price=0 Quantity=100 Type=Limit Filled=0 Fill price=0 Error=NoError Native error=''


    11/01/2010 9:36:31|1|32|Order='1f03701:029a/XXXXXXXX' Name='Profit target' New State=PendingCancel Instrument='Instrument 4' Action=BuyToCover Limit price=XX,06 Stop price=0 Quantity=100 Type=Limit Filled=0 Fill price=0 Error=NoError Native error=''


    It lists a PendingCancel status, which indicates they are cancelled from within the software. What actions did you perform within the software around 9:36:31?


    Sincerely,
    Jason Hilling

    = = = = = = = =
    Hi, Jason

    As far as I recall, I didn't do anything within the trading software at the time. I trade with one copy of NT on a computer dedicated to trading, and - while it's trading - I work on another computer (where I have a free license for NT) developing other trading strategies.

    At the time of the profit target exit of "Instrument 2"/B1, I don't think I was touching the trading computer. I would have heard the audio NT alert that the position had been exited, and also "order cancelled" ... a few moments later I noticed my working orders (stop/profit target) for "Instrument 1"/A and "Instrument 4"/B3 had also been cancelled.

    What makes me suspicious that the cancellations were software generated (NT or MBT Navigator?) is that they follow the "Instrument 2"/B1 exit by about 1 second....

    = = = = = = = =
    On Mon, Jan 11, 2010 at 1:18 PM, NinjaTrader Customer Service <[email protected]> wrote:

    Hello,

    Thank you for your response.

    It should not be related to the other strategy, since automated strategies run independent from each other, see the forum thread below.

    http://www.ninjatrader-support2.com/vb/showthread.php?t=21812&highlight=independent

    Could it be strategy B1 references strategies A and B3?

    Does this behavior always occur when the profit target of strategy B1 executes?

    Unfortunately I am not very proficient in NinjaScript and programming and would not know how this would look in the code of B1.

    If it is not inconvenient for you, we appreciate all NinjaScript related questions be directed to our support forum. This helps us build our knowledge base for future users. There is a very active developer community in our support forum that supplements the responses provided by NinjaTrader support staff providing all users with an exceptional support experience.

    Sincerely,
    Jason Hilling
    NinjaTrader Customer Service


    = = = = = = =
    Hi, Jason

    Q: Could it be strategy B1 references strategies A and B3?
    A: THE CODE FOR B1 DOES NOT REFERENCE A OR B3, UNLESS THERE IS SOME HIDDEN/IMPLICIT WAY (THAT I AM NOT AWARE OF) THAT THE CODE OF A RUNNING STRATEGY CAN REFERENCE ANOTHER RUNNING STRATEGY ...


    Q: Does this behavior always occur when the profit target of strategy B1 executes?
    A: TODAY WAS THE FIRST TIME THE FOUR INSTRUMENT STRATEGY COMBINATIONS ALL TOOK POSITIONS AT THE OPEN, SO I DON'T YET KNOW IF THIS IS SOMETHING THAT WILL "ALWAYS" OCCUR IN THIS SITUATION ...

    I'll move this to the Support Forum now.

    Thanks
    Last edited by AnotherTrader; 01-11-2010, 12:54 PM.

    #2
    From: NinjaTrader Customer Service <[email protected]>
    Date: Mon, Jan 11, 2010 at 1:33 PM
    Subject: RE: Cancelled stop/profit target orders {265112}


    Hello,

    Thank you for your response.

    That could be an explanation of the issue. Strategy B1 contains code that will cancel the profit target of the other strategies.

    Did you create these strategies yourself or did you obtain them from a third party vendor?

    Unfortunately I am not very proficient in programming and would not know how to check this.



    Sincerely,
    Jason Hilling
    = = = = = = = = = = = =

    These are strategies that I have created myself ...

    I would like to understand better in what ways one running strategy might result in cancelation of the orders in another?

    Comment


      #3
      Hello AnotherTrader,

      Since you did not code your strategy that way, it should not be related to the code of strategy B1.

      The log file listed a PendingCancel status, which indicates the orders have been manually cancelled within the software.

      I suggest to run the strategies in simulation and check if profit targets of strategy A and B3 are cancelled, once profit target of B2 executes.
      JasonNinjaTrader Customer Service

      Comment


        #4
        At today's open, all four instrument/strategy combos again took positions, for the second day in a row.

        But this time, all profit target/stop orders executed as intended without unexpected cancellations.

        As far as I can tell, there was no difference between how I ran my trading set-up today and yesterday, so I don't know what caused yesterday's anomalies.

        However, as I am now comfortable that yesterday's order cancellations are unlikely to be due to a coding error - and more likely to some intermittent factor or causes that didn't repeat today - I'm not going to look further into this issue for now.

        If it occurs again, I'll try to get some more information about the circumstances when it occurs, and then I'll rekindle this thread ...

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by DJ888, 04-16-2024, 06:09 PM
        4 responses
        12 views
        0 likes
        Last Post DJ888
        by DJ888
         
        Started by terofs, Today, 04:18 PM
        0 responses
        11 views
        0 likes
        Last Post terofs
        by terofs
         
        Started by nandhumca, Today, 03:41 PM
        0 responses
        7 views
        0 likes
        Last Post nandhumca  
        Started by The_Sec, Today, 03:37 PM
        0 responses
        3 views
        0 likes
        Last Post The_Sec
        by The_Sec
         
        Started by GwFutures1988, Today, 02:48 PM
        1 response
        9 views
        0 likes
        Last Post NinjaTrader_Clayton  
        Working...
        X