Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

entry orders canceled for some reason

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

    entry orders canceled for some reason

    25.8.2011 3:00:03|1|32|Order='be516ff2fe9a46f0ac8ab439ec7c89 a7/DU108063' Name='short' New state=PendingSubmit Instrument='$NOKSEK' Action=SellShort Limit price=1,1648 Stop price=0 Quantity=0,15M Type=Limit Filled=0 Fill price=0 Error=NoError Native error=''
    25.8.2011 3:00:03|2|4|Order Event Warning:Attribute 'Outside Regular Trading Hours' is ignored based on the order type and destination. PlaceOrder is now being processed. 2109
    25.8.2011 3:00:03|1|32|Order='145024456/DU108063' Name='short' New state=Accepted Instrument='$NOKSEK' Action=SellShort Limit price=1,1648 Stop price=0 Quantity=0,15M Type=Limit Filled=0 Fill price=0 Error=NoError Native error=''
    25.8.2011 3:00:03|1|32|Order='145024456/DU108063' Name='short' New state=Working Instrument='$NOKSEK' Action=SellShort Limit price=1,1648 Stop price=0 Quantity=0,15M Type=Limit Filled=0 Fill price=0 Error=NoError Native error=''
    25.8.2011 3:05:01|1|32|Order='145024456/DU108063' Name='short' New state=PendingCancel Instrument='$NOKSEK' Action=SellShort Limit price=1,1648 Stop price=0 Quantity=0,15M Type=Limit Filled=0 Fill price=0 Error=NoError Native error=''
    25.8.2011 3:05:01|1|32|Order='145024456/DU108063' Name='short' New state=Cancelled Instrument='$NOKSEK' Action=SellShort Limit price=1,1648 Stop price=0 Quantity=0,15M Type=Limit Filled=0 Fill price=0 Error=NoError Native error='Order Canceled - reason: (202)'


    Strategy is running on IB FX on 5min bars.
    Why are the entry orders canceled?
    Could it be caused if the stop and targets are adjusted on next closed 5min bar, before entry is filled?

    This same thing happened on wednesday.
    On wednesday the historical backtest shows it should have been filled and executed properly. But it wasnt, I am seeing the same thing in the logs.

    #2
    naxo79, you would need to let your strategy run with TraceOrders = true in the Initialize() and then open up the output window from the Control Center, it would then show more details regarding the order submission and cancellation / expiration reasons. For the native 202 error reported by IB, please contact them directly.
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Here's the output from traceorders:


      25.8.2011 21:15:05 Entered internal SetStopTarget() method: Type=Stop FromEntrySignal='' Mode=Price Value=1,15675217325051 Currency=0 Simulated=False
      25.8.2011 21:15:05 Entered internal SetStopTarget() method: Type=Target FromEntrySignal='' Mode=Price Value=1,16763762263581 Currency=0 Simulated=False
      25.8.2011 21:15:05 Entered internal PlaceOrder() method at 25.8.2011 21:15:05: BarsInProgress=0 Action=Buy OrderType=Limit Quantity=0,15M LimitPrice=1,1637 StopPrice=0 SignalName='long' FromEntrySignal=''
      25.8.2011 21:20:36 Entered internal SetStopTarget() method: Type=Stop FromEntrySignal='' Mode=Price Value=1,15666309039362 Currency=0 Simulated=False
      25.8.2011 21:20:36 Entered internal SetStopTarget() method: Type=Target FromEntrySignal='' Mode=Price Value=1,16752695388794 Currency=0 Simulated=False
      25.8.2011 21:20:36 Entered internal PlaceOrder() method at 25.8.2011 21:20:36: BarsInProgress=0 Action=Buy OrderType=Limit Quantity=0,15M LimitPrice=1,1647 StopPrice=0 SignalName='long' FromEntrySignal=''
      25.8.2011 21:20:36 Amended matching order: Action=Buy OrderType=Limit Quantity=150000 LimitPrice=1,1647 StopPrice=0 SignalName=long' FromEntrySignal=''
      25.8.2011 21:26:42 Cancelled expired order: BarsInProgress=0: Order='145024462/DU108063' Name='long' State=Working Instrument='$NOKSEK' Action=Buy Limit price=1,1647 Stop price=0 Quantity=0,15M Strategy='regv72' Type=Limit Tif=Gtc Oco='' Filled=0 Fill price=0 Token='3039d53e25d54f3bbdde7388bdecba91' Gtd='1.12.2099 0:00:00'

      It seems the order expires when the next 5m bar is closed after the entry condition is triggered?

      Comment


        #4
        Hi naxo79,

        This is the default behavior for orders unless you use advanced overload and set liveUntilCancelled = true. They are cancelled if they're not filled on the bar they're submitted to.

        EnterLongLimit(int barsInProgressIndex, bool liveUntilCancelled, int quantity, double limitPrice, string signalName)
        Ryan M.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by fx.practic, 10-15-2013, 12:53 AM
        5 responses
        5,404 views
        0 likes
        Last Post Bidder
        by Bidder
         
        Started by Shai Samuel, 07-02-2022, 02:46 PM
        4 responses
        95 views
        0 likes
        Last Post Bidder
        by Bidder
         
        Started by DJ888, Yesterday, 10:57 PM
        0 responses
        8 views
        0 likes
        Last Post DJ888
        by DJ888
         
        Started by MacDad, 02-25-2024, 11:48 PM
        7 responses
        159 views
        0 likes
        Last Post loganjarosz123  
        Started by Belfortbucks, Yesterday, 09:29 PM
        0 responses
        8 views
        0 likes
        Last Post Belfortbucks  
        Working...
        X