Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Orders Function Question

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

    Orders Function Question

    I'd like to simplify my process for acquiring an Open Orders List. (Hint: It would be useful for NJ to create a function to return this list.)

    I was thinking that I would parse the Order Function return string and then stop after some number of orders known to be open. But this presumes that the order string is constructed according to some sort order.

    What is that order?

    Any other ideas on how best to get that list of OpenOrderIds?

    #2
    imported post

    Hi,

    Not sure what you mean:
    1) ATI function "Orders" returns a "list" of order IDs submitted via ATI.
    2) ATI function "OrderStatus" returns the order state per order.

    Using both functions you should be able to achieve what you are looking for.

    Comment


      #3
      imported post

      Hi,

      Yes. I understand. But consider this.

      I want to my systems to ensure that no orders are left hanging in an "Active" state inadvertently. For me to write code that manages orders in the "Active" state I need to get that list of "Active" orders. ("Active" being a state of several different OrderID states documented in the Help File.)

      But the current ATI Orders function returns the entire list of orders whether Active or not and includes those orders placed hours and hours in the past. The current ATI Orders function is going to be returning a very long string when it is called especially as the trading day progresses and the number of orders placed via the ATI increases.

      I think the ATI function list is missing a function that only returns strings of OrderIDs with specific statuses AND includes the "Active" status.

      But until that exists, I need to process that very long Orders string myself to ensure that I have the complete list of Active orders.

      It makes no sense for my system to maintain a list of OrderIDs and Statuses when Ninja Trader has them. But I don't want to have to process the COMPLETE string of OrderIDs for status every time I need a status update.

      I would prefer NOT to have to:

      1 ) check the status of every order returned as part of that string through a call to OrderStatus.

      2 ) keep an array of OrderIDs and statuses myself so I know what orders are still Open and what orders are closed

      So, I was thinking that if the Order String was constructed according to some specific sort order that I could reasonably limit my search of Order Status to those OrderIDs that might be Open and NOT have to search the whole string.

      Think about it...

      You would never expect discretionary traders to search through the complete list of orders to be able to see just the ones that are "Active". In fact, you've already developed a method for limiting the list of Orders appearing on the Orders tab to those that are Active.

      But system traders must currently do their own churning of OrderIDs and Statuses to get the list of Active Orders.

      I just want access to THAT method available to discretionary traders or a suggestion from you about how I might NOT have to check 100 Order Statuses to find the 2 OrderIDs that are Active.

      Comment


        #4
        imported post

        Hi guys...

        Thoughts about this?

        Comment


          #5
          imported post

          Dierk is on vacation and will likely provide thoughts on this later this week.


          Ray
          RayNinjaTrader Customer Service

          Comment


            #6
            imported post

            There is no performance impact. The information you are looking for already is in the address space of the requesting app (e.g. TradeStation). It really does not matter (from NT's perspective) if you process 10 or 1000 order status requests. I guess you would not even notice if you would run a timer on it.

            However, I see your point and will put it on the list for future considerations.

            Comment


              #7
              imported post

              I understand.

              But I'm not using Tradestation. And I've written my own interface to Ninja Trader from within NeoTicker. So, the only Order List I have accessible to me is the one within Ninja Trader.

              What I did was create a set of string lists for Orders in various states. But reconciliation with the Order List in Ninja Trader including the states of those Orders isn't a simple thing.

              So, it would be EXTREMElY handy to be able to get the "Open Order List" from Ninja.

              Thanks.

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by usazencort, Today, 01:16 AM
              0 responses
              1 view
              0 likes
              Last Post usazencort  
              Started by kaywai, 09-01-2023, 08:44 PM
              5 responses
              603 views
              0 likes
              Last Post NinjaTrader_Jason  
              Started by xiinteractive, 04-09-2024, 08:08 AM
              6 responses
              22 views
              0 likes
              Last Post xiinteractive  
              Started by Pattontje, Yesterday, 02:10 PM
              2 responses
              21 views
              0 likes
              Last Post Pattontje  
              Started by flybuzz, 04-21-2024, 04:07 PM
              17 responses
              230 views
              0 likes
              Last Post TradingLoss  
              Working...
              X