• 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

Please, help me to join in my head WaitUntilFlat and GetRealtimeOrder()

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

    Please, help me to join in my head WaitUntilFlat and GetRealtimeOrder()

    Hello.

    Say, we have a strategy with start behaviour WaitUntilFlat.
    And, say, it State == State.Transition strategy has position and protective orders.

    Considering WaitUntilFlat, should strategy do GetRealtimeOrder() for the protective orders?

    if convert orders to realtime, strategy will have "virtual" position and real orders, right?
    And what will happen when a virtual position meets real order?

    I am strongly needed order in my head )

    Thanks in advance.
    fx.practic
    NinjaTrader Ecosystem Vendor - fx.practic

    #2
    Hello fx.practic,

    GetRealtimeOrder is only used to transition orders which are currently active in historical data. If the protective orders are still active and they will be active in Realtime and need to be managed then you need to do that.

    This method is only needed if you have historical order references which you wish to transition and manage in real-time (i.e., you had a working order which was submitted historically and re-submitted in real-time as the strategy is enabled).
    https://ninjatrader.com/support/help...ub=getrealtime


    if convert orders to realtime, strategy will have "virtual" position and real orders, right?
    And what will happen when a virtual position meets real order?
    Your strategy always has a virtual position and the orders being real would depend on the start behavior. Wait until flat will compare the strategy position, in that case you would not have a flat position entering realtime so the orders would just be virtual until the strategy reaches flat. Once you are flat and also in realtime it could start placing real orders.

    If the Strategy Position is flat, then the Account Position and Strategy Position are assumed to be in sync with each other. The next order placed by your strategy would be placed as a live order to your account.

    If the Strategy Position is not flat, the strategy will place all trades in a "virtual" sense until the Strategy Position reaches or crosses a flat state. Once a flat state is achieved the Strategy Position will be assumed to be in sync with the Account Position and all future orders will be placed live.
    https://ninjatrader.com/support/help...#WaitUntilFlat


    I look forward to being of further assistance.
    JesseNinjaTrader Customer Service

    Comment


      #3
      "the orders would just be virtual until the strategy reaches flat"
      Yahoo, the clarity came to me!
      Thanks a lot, Jesse!
      fx.practic
      NinjaTrader Ecosystem Vendor - fx.practic

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by aaadetos, Yesterday, 08:39 PM
      0 responses
      5 views
      0 likes
      Last Post aaadetos  
      Started by Teebone21, Yesterday, 03:57 PM
      0 responses
      5 views
      0 likes
      Last Post Teebone21  
      Started by GeoOrtiz, Yesterday, 03:44 PM
      0 responses
      7 views
      0 likes
      Last Post GeoOrtiz  
      Started by ralett, Yesterday, 03:41 PM
      1 response
      8 views
      0 likes
      Last Post NinjaTrader_Tyler  
      Started by Walker DM, Yesterday, 03:14 PM
      2 responses
      12 views
      0 likes
      Last Post Walker DM  
      Working...
      X