Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Close quantity more than entry quantity

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

    Close quantity more than entry quantity

    Hi NT experts,

    When a strategy's close quantity (from stop or target orders) is more than the entry order quantity, will the strategy (like OnBarUpdate) continue to function?

    For example, when shorting 1 ES contract at the entry and exit with 2 ES contract at buy back, this will result in a net long position. Will a strategy continue to run for this long position?

    #2
    binwang2, the strategy would continue to run, but might not deliver the results expected as the position synching would be off -



    Could you please clarify more the scenario behind this?

    When you're synced up properly at strategy startup this should not be an issue (except for potential overfills) -

    BertrandNinjaTrader Customer Service

    Comment


      #3
      The strategy had exited majority positions already. Then it fired a market order to close remaining positions. The market order is simple enough as the folloing:
      EXitLong();
      However, it sold more quantities than the remaining positions and I ended up with a net short position.
      From sell action on, the strategy seemed no longer processing data, even though it was not frozen: i closed my strategy manaully on chart trader.

      Comment


        #4
        The strategy continue to act as expected, but since the stratregy vs account position sync was off the results were not what you expected. In case you had gotten an overfill, you would need to step in and make sure synching is achieved by manually placing orders to account for the difference seen.
        BertrandNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by pvincent, 06-23-2022, 12:53 PM
        14 responses
        238 views
        0 likes
        Last Post Nyman
        by Nyman
         
        Started by TraderG23, 12-08-2023, 07:56 AM
        9 responses
        382 views
        1 like
        Last Post Gavini
        by Gavini
         
        Started by oviejo, Today, 12:28 AM
        0 responses
        1 view
        0 likes
        Last Post oviejo
        by oviejo
         
        Started by pechtri, 06-22-2023, 02:31 AM
        10 responses
        125 views
        0 likes
        Last Post Leeroy_Jenkins  
        Started by judysamnt7, 03-13-2023, 09:11 AM
        4 responses
        59 views
        0 likes
        Last Post DynamicTest  
        Working...
        X