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

Manage multiple orders in a strategy independently

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

    Manage multiple orders in a strategy independently

    Hi there,

    Hope everyone is doing well today.

    I currently have a strategy that allows up to 3 entry orders at one time with 3 different profit targets. However, there is only 1 stop loss for all 3 orders. So when the 3 orders are placed, the stop loss and breakeven is the same for all 3.

    We need the strategy to manage each order separately so we can have different targets, stops, breakevens, and trailing stop settings for each order independently.

    Does anyone have a code sample they could share to help us structure what this should look like when each order is managed independently?

    Also, has anyone had any problems when trading live using multiple independent orders going out all at once?


    #2
    Hello tjfintrade,

    Thanks for your post.

    Managing multiple entry/exit orders is controlled by the 'Signal Name' and 'From Signal Name' properties. You would give each entry order a Signal Name of something like "Entry1", "Entry2", and "Entry3". Then you would set your Exit order's 'From Signal Name' property to "Entry1", "Entry2", and "Entry3" to tie the exit orders to the entries. You could also give the Exit orders a 'Signal Name' such as "Exit1", "Exit2", and "Exit3".

    You could then add your logic to the strategy for moving each stop to breakeven or trailing the stops.

    This sample can assist further with managing multiple entry/exit signals:
    https://ninjatrader.com/support/helpGuides/nt8/en-us/using_multiple_entry_exit_sign.htm

    My colleague Chelsea has created educational examples of strategy builder breakeven and trailing stop in the strategy builder here which you might find helpful:
    https://ninjatrader.com/support/foru...der#post806596
    Brandon H.NinjaTrader Customer Service

    Comment


      #3
      tjfintrade My AddOn software (Mizpah Trade Manager) can submit up to 41 Orders in each of up to 7 Instruments in each of up to 8 different Accounts in a single "trade". A quick calculation will show you that the software can submit and manage up to 2,296 separate Orders in a single trade, and whilst all Orders are managed within the parameters set for StopLoss and Profit Target, each and every Order is managed individually. So, to answer your last question, no problems at all, other than knowing what to do and programming it correctly.

      Thanks.
      Multi-Dimensional Managed Trading
      jeronymite
      NinjaTrader Ecosystem Vendor - Mizpah Software

      Comment


        #4
        Originally posted by NinjaTrader_BrandonH View Post
        Hello tjfintrade,

        Thanks for your post.

        Managing multiple entry/exit orders is controlled by the 'Signal Name' and 'From Signal Name' properties. You would give each entry order a Signal Name of something like "Entry1", "Entry2", and "Entry3". Then you would set your Exit order's 'From Signal Name' property to "Entry1", "Entry2", and "Entry3" to tie the exit orders to the entries. You could also give the Exit orders a 'Signal Name' such as "Exit1", "Exit2", and "Exit3".

        You could then add your logic to the strategy for moving each stop to breakeven or trailing the stops.

        This sample can assist further with managing multiple entry/exit signals:
        https://ninjatrader.com/support/helpGuides/nt8/en-us/using_multiple_entry_exit_sign.htm

        My colleague Chelsea has created educational examples of strategy builder breakeven and trailing stop in the strategy builder here which you might find helpful:
        https://ninjatrader.com/support/foru...der#post806596


        Thanks, Brandon,

        I was also trying to see if it's possible to add a feature with a dropdown that will allow us to select an ATM strategy from the list of custom ATM strategies we already have for each order. Is there a code sample for that?

        Comment


          #5
          Hello tjfintrade,

          Thanks for your notes.

          Please view the example strategy shared by my colleague Chris on the forum thread linked below which demonstrates how to create a custom ATM selector in your script.

          AtmStrategySelectorExample: https://forum.ninjatrader.com/forum/...55#post1053755
          Brandon H.NinjaTrader Customer Service

          Comment


            #6
            NinjaTrader_BrandonH​ Thank you for the quick response! We will review the code samples.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Jonafare, 12-06-2012, 03:48 PM
            5 responses
            3,984 views
            0 likes
            Last Post rene69851  
            Started by Fitspressorest, Today, 01:38 PM
            0 responses
            2 views
            0 likes
            Last Post Fitspressorest  
            Started by Jonker, Today, 01:19 PM
            0 responses
            2 views
            0 likes
            Last Post Jonker
            by Jonker
             
            Started by futtrader, Today, 01:16 PM
            0 responses
            7 views
            0 likes
            Last Post futtrader  
            Started by Segwin, 05-07-2018, 02:15 PM
            14 responses
            1,791 views
            0 likes
            Last Post aligator  
            Working...
            X