Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Do TIF=Day "Limit Orders" work fine on public holidays?

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

    Do TIF=Day "Limit Orders" work fine on public holidays?

    at what time does a TIF=Day Limit order get cancelled, is it 1 minute before session end, or some other time like 3 minutes, does it get cancelled or does it just expire, does ninjatrader or the CME exchange itself cancel the order just before session end (Which one?), what happens on USA public holidays - how would ninja know the time to cancel the order when ninja would not know in advance the exact time the session finishes early on that day due to the public holiday - how does this work, or does the limit order expire when the exchange is closed for the public holiday? thank you in advance.

    #2
    Hi Rocket130713, currently there's no dedicated holiday session handling per se in NT, the cancellation / end of session handling would be occurring as per the current session hours used. In your TraceOrders output you would also see this handling triggered for any orders still working, unless submitted via GTC of course.

    For live orders this would be a function of your broker's backend routing to the exchange.
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Hi Bertrand, thank you for your reply. I forget how Ninja handles TIF=day "limit" orders as I tested this years ago and now have not got a live test environment set-up at the moment. Does Ninja still "Cancel" the limit order 1 minute before session end like for Jap yen on CME at 4:59 PM when setting TIF to "Day"? (or does it cancel 5 minutes before session end, or 30 seconds before session end?).

      Also, if there is a public holiday and Ninja fails to cancel the limit order before the end of session, will this limit order just simply "expire" when the CME exchange closes down for the public holiday due to the fact that the order is sitting at the exchange and was initially submitted by ninja as "day" order and all day orders "automatically" expire at the end of the session at the CME. Also the CME assumes that all orders submitted are "day" orders unless they are submitted as something else like a GTC order. Is this how it works Bertand, or have a made some errors in the above information, could you please explain how this works? I just need to get this info 100% correct so I can program our order handling stuff correctly. thanks in advance.

      Comment


        #4
        Hi Rod, per default limit orders in NT expire at the end of the bar they were submitted, irregardless of the TIF. With the unmanaged mode or setting orders in managed to liveUntilCancelled, they TIF would come into play. For live orders the CME / exchange would cancel them when the trading goes into 'Closed' state. The NT simulated orders end of session handling would be determined by the primary session template in your script, if this would end at 16:15 for example > that's when you would see the order getting cancelled due to End of session handling in your NT order traces / output window.
        BertrandNinjaTrader Customer Service

        Comment


          #5
          Bertrand,

          Does NT has only 3 types of TIF: day, gtc, and gtd?
          Can we set tif of a NT limit order during simulation like TIF = "5Min"?

          Thanks.

          ccl3093

          Comment


            #6
            Hello ccl3093,

            NT supports two types of TIF orders, GTC and Day.

            You can use TIF in your order submission.

            This is set in the Initialize() method and is set for all your orders -
            http://www.ninjatrader.com/support/h...imeinforce.htm
            Cal H.NinjaTrader Customer Service

            Comment


              #7
              Regarding placing TIF=Day "limit orders" using TradeStation and Ninja DLL method, if we place a BUY 10 contracts limit order and this order gets "part-filled" with 5 lots filled and 5 lots still outstanding, will the "un-filled" component of the limit order automatically "expire" at the end of the session??? Or do we have to cancel the remaining 5 contracts order manually? Thank you in advance.
              Last edited by Rocket130713; 05-09-2014, 07:51 AM.

              Comment


                #8
                Hello Rocket130713,

                The order itself will get cancelled automatically for the TIF = Day, however the filled portions will still remain open on the account.
                Cal H.NinjaTrader Customer Service

                Comment


                  #9
                  if i submit a buy 10 limit order (to open a position) TIF=Day on wednesday 3pm CT and it remains part-filled until the session ends, and then the order expires at 4:00 pm CT when the session is closed, the next day when i call ninja orderstatus() function for the buy 10 limit "entry" order will this function return a "cancelled" or "part-filled" order state string???

                  also a second question, if i place a buy 10 contracts "exit" order and it gets filled for 10 contracts, and did this trade 3 months ago and i then call OrderStatus() today (3 months later) will i still get a "filled" order state even though this order was placed a long time ago and within the 3 months i have opened and closed down the ninja platform many times, or, will the status for this order get lost as so much time has passed and if it gets lost i would get an empty string when i call orderstatus()??? what would happen in this example???

                  Comment


                    #10
                    Hello Rocket130713,

                    Thank you for your post.

                    The order's state will reflect the last status update, so this would then be cancelled for the state of the order.

                    The orders from previous runs of the strategy will be unavailable to the current run of the strategy. The strategies can only see the orders from the current run, the orders that were submitted since the strategy was enabled.

                    Please let me know if I may be of further assistance.

                    Comment


                      #11
                      In my Sim101 account, my buy 100 limit order remains part-filled "order state" for 3 days and does not convert to an order state of "cancelled" at the end of the session even though the limit order i placed was a TIF = Day order. Is this normal in all Sim101 accounts? Also is this the type of order behaviour i should expect in a live trading account? Or is it the case for a live trading account (for a limit order that remains part-filled that is also a TIF = day order) the Ninja order state will become a "cancelled" order state at the end of the session? I am calling the Ninja Order State by calling the NTOrderStatus("Entry#1") DLL function from within my TradeStation EasyLanguage strategy code.

                      I also thought that for live trading, if a working order (or part-filled order) "expires" (at the end of trading session) at the CME exchange because the order was submitted as a "TIF = Day" order and the actual order was not filled within the session it was initially placed, then Ninja would report the state of this order as "cancelled" when we call the DLL NT function NTOrderStatus("Entry#1") during the "following" session, is this correct?
                      Last edited by Rocket130713; 05-27-2014, 04:43 AM.

                      Comment


                        #12
                        Hello Rocket130713,

                        Thank you for your response.

                        This is not expected behavior and would not be seen on a live account. If an order does get stuck you can correct it on a live account by repairing the database as the broker will likely have the correct order state on their end. To resolve this for the SIM101 account please reset your simulator by going to Tools > Options > Simulator > Reset.

                        Please let me know if I may be of further assistance.

                        Comment


                          #13
                          thank your reply. much appreciated. I am about to do live trading again in a few weeks time with a new system, so I have not got a live PATS connection at the moment so I cant test this stuff on my end, just want to make sure I dont make any mistakes with the order handling, I apologize for the confusion on my end.

                          Just to be sure, for "live trading" if I place a Limit order in the ninja platform with a Time In Force (TIF) set to "Day" will Ninja automatically report an OrderState of "Cancelled" (in the logs) at the end of the session if the order is not Filled or Part-Filled at the CME exchange?

                          Thanks in advance for all of your help. Really appreciate this
                          Last edited by Rocket130713; 05-29-2014, 08:30 AM.

                          Comment


                            #14
                            Hello Rocket130713,

                            Thank you for your response.

                            That is correct, the TIF of Day means the order will be cancelled if not filled by the end of the session.

                            Comment

                            Latest Posts

                            Collapse

                            Topics Statistics Last Post
                            Started by helpwanted, Today, 03:06 AM
                            0 responses
                            3 views
                            0 likes
                            Last Post helpwanted  
                            Started by Brevo, Today, 01:45 AM
                            0 responses
                            6 views
                            0 likes
                            Last Post Brevo
                            by Brevo
                             
                            Started by aussugardefender, Today, 01:07 AM
                            0 responses
                            5 views
                            0 likes
                            Last Post aussugardefender  
                            Started by pvincent, 06-23-2022, 12:53 PM
                            14 responses
                            242 views
                            0 likes
                            Last Post Nyman
                            by Nyman
                             
                            Started by TraderG23, 12-08-2023, 07:56 AM
                            9 responses
                            384 views
                            1 like
                            Last Post Gavini
                            by Gavini
                             
                            Working...
                            X