• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Cancel command taking to long in Simulator

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

    Cancel command taking to long in Simulator

    I am having trouble getting NT to accept an OIF command, after a Cancel command. The Cancel command has not finished being processed in NT when NT starts processing the OIF command. NT has accepted the Cancel command because the Cancel file has been deleted. I check for this condition (Cancel file does not exist) before I send the OIF command in the Order file. It seems that NT can't get out of it's own way, fast enough



    Code:
    "3/31/2005 2:09:39 PM ORDER STATUS TARGET1 ER2 06-05: FILLED B Type:LIMIT Qty:2 @ Limit Price:613.3 Stop Price:0 Position Id:ER2 06-05 SIM-101 90143321818 Order Id:90144447SIM Simulation"
    "3/31/2005 2:09:41 PM ORDER STATUS STOP1 ER2 06-05: CANCELING B Type:STOPMARKET Qty:2 @ Limit Price:0 Stop Price:614.4 Position Id:ER2 06-05 SIM-101 90143321818 Order Id:90144446SIM Simulation"
    "3/31/2005 2:09:41 PM ORDER STATUS STOP1 ER2 06-05: CANCELLED B Type:STOPMARKET Qty:2 @ Limit Price:0 Stop Price:614.4 Position Id:ER2 06-05 SIM-101 90143321818 Order Id:90144446SIM Simulation"
    "3/31/2005 2:11:35 PM SUBMIT ORDER ENTRY1: S 2 @ Limit Price:1183.5 Stop Price:1183.5 Order Id: Position Id:ES 06-05 SIM-101 90143592119 Simulation"
    "3/31/2005 2:11:35 PM ORDER STATUS ENTRY1 ES 06-05: PENDING S Type:STOPLIMIT Qty:2 @ Limit Price:1183.5 Stop Price:1183.5 Position Id:ES 06-05 SIM-101 90143592119 Order Id: Simulation"
    "3/31/2005 2:11:39 PM ORDER STATUS ENTRY1 ES 06-05: ACP_XCHG S Type:STOPLIMIT Qty:2 @ Limit Price:1183.5 Stop Price:1183.5 Position Id:ES 06-05 SIM-101 90143592119 Order Id:9014113548SIM Simulation"
    "3/31/2005 2:16:33 PM CANCEL ORDER ENTRY1: S 2 @ Limit Price:1183.5 Stop Price:1183.5 Order Id:9014113548SIM Position Id:ES 06-05 SIM-101 90143592119 Simulation"
    "3/31/2005 2:16:33 PM ORDER STATUS ENTRY1 ES 06-05: CANCELING S Type:STOPLIMIT Qty:2 @ Limit Price:1183.5 Stop Price:1183.5 Position Id:ES 06-05 SIM-101 90143592119 Order Id:9014113548SIM Simulation"
    "3/31/2005 2:16:34 PM AT 'ORDER OIF' ABORTED: Can't place order while entry order is pending"
    "3/31/2005 2:16:37 PM ORDER STATUS ENTRY1 ES 06-05: CANCELING S Type:STOPLIMIT Qty:2 @ Limit Price:1183.5 Stop Price:1183.5 Position Id:ES 06-05 SIM-101 90143592119 Order Id:9014113548SIM Simulation"
    "3/31/2005 2:16:37 PM ORDER STATUS ENTRY1 ES 06-05: CANCELLED S Type:STOPLIMIT Qty:2 @ Limit Price:1183.5 Stop Price:1183.5 Position Id:ES 06-05 SIM-101 90143592119 Order Id:9014113548SIM Simulation"

    #2
    imported post

    That is not the issue.

    Simulation is driven by market data. If data is coming in slow, the simulator will respond slow. Also, any order actions performed in the simulator have a delay that is internally simulated or based on an actual real-time internet delay. The internet delay is based on round trip time from your PC to our servers. If you have bad internet connection during that time, the delay will be representative of this scenario.


    Ray
    RayNinjaTrader Customer Service

    Comment


      #3
      imported post

      The issue is should you be starting another AT command before the last has finished.

      Comment


        #4
        imported post

        If thats true, thats a problem. I look for the same condition, i.e.

        CANCELALL

        then

        FLATTENALL

        then issue the brand new OIF (order.txt)

        I look for the absence condition, if absence = true, only then issue next OIF.

        But looks like, here, the CANCEL has not finished, yet NT reports (via deletion of file) that it has completed the CANCEL operation.

        Ray, comments ?

        Comment


          #5
          imported post

          It processes once the command has been proccesed not once the functions of the operation is complete. In the simulator, the cancel/flatten could have delay since it is market data driven. In realtime, it's command driven.
          RayNinjaTrader Customer Service

          Comment


            #6
            imported post

            Ok, thanks. So if I put lets say 60 secs delay after the CANCELALL , that should be ENOUGH to guarantee ..... a graceful completed CANCEL ..... both for simulation and realtime ...... ?

            Comment


              #7
              imported post

              For realtime you don't only need a few seconds, for simulation 60 seconds is plenty during standard market hours.
              RayNinjaTrader Customer Service

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by zergrush, Today, 12:17 AM
              3 responses
              15 views
              0 likes
              Last Post NinjaTrader_ChristopherS  
              Started by HiddenPhilosopher, Today, 03:53 AM
              0 responses
              4 views
              0 likes
              Last Post HiddenPhilosopher  
              Started by Leeroy_Jenkins, Today, 03:00 AM
              0 responses
              7 views
              0 likes
              Last Post Leeroy_Jenkins  
              Started by KhaosTrader, Yesterday, 11:04 PM
              1 response
              10 views
              0 likes
              Last Post NinjaTrader_Marco  
              Started by rcsingleton, Today, 12:28 AM
              1 response
              10 views
              0 likes
              Last Post NinjaTrader_ChrisSch  
              Working...
              X