Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

automated trading and calculations for stop orders.

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

    automated trading and calculations for stop orders.



    people with nt,



    i have been having an issue with nt. i will try to be as clear as possible.



    if one has a strategy enabled to trade automated and it has been running without problems then stop loss and profit target orders will be properly calculated for every entry.


    however, if for any reason the strategy was not enabled or working at the time of an entry then that entry was not made at the right time and price. if one synchronizes the strategy later on, the entry price for the strategy and the entry price for the account will not be identical and the strategy will not calculate stops using the real world position of the account but rather its own theoretical entry price (which does not correspond to that of the account).


    ¿is there any setting in the nt platform that can be configured so that strategies will always use account values for entry prices, position sizes and everything else after synchronization or recalculation? if not, having strategies that do not observe maximum loss amounts would completely negate all risk management considerations in the strategies themselves. hopefully nt should have some mechanism somewhere to accomplish this.


    #2
    Hello rtwave,

    Thank you for your post.

    the strategy will not calculate stops using the real world position of the account but rather its own theoretical entry price
    Are you referring to when the strategy is calculating a historical (virtual) position?

    What color is the strategy in the Strategies tab of the Control Center when you enable the strategy and see this behavior?

    What Start Behavior setting is your strategy set to use when you enable it?

    I look forward to assisting further.

    Comment


      #3




      a strategy is enabled on a chart for an instrument. at a price of 1,200 the conditions for a short position are observed and the strategy will sell one contract and also set a stop loss order at 1,210.


      all is correct.


      however, if due to a disconnection or any other reason one gives the command to synchronize the same strategy but only much later in the session when price is already at 1,960 and the account is flat, then the strategy will sell one contract at that price of 1,960 but the stop will not be set at 1,970 as would correspond to the maximum loss, but at 1,220 which would correspond to the entry that the strategy would have made but was not observed.



      that is what i am talking about. i'm asking for a method to have strategies " adopt " real world account entry prices, position sizes, and so on.


      Comment


        #4
        Hello rtwave,

        Thank you for your response.

        You may want to try out 'Adopt Account Position' for the start behavior. When the position is adopted from the account, this will give the Position.AveragePrice from the account, which can be used to calculate the stop and target distance.



        Try testing out this sample script from the forum post below and see if this is the behavior you are looking for.



        If you have any further questions, please let us know.

        Comment


          #5


          people with nt,




          i have found methods to adjust the execution of strategies trading automated.



          one can change position sizes by disabling the strategy, modifying the parameters manually, re-enabling and if the strategy is configured to immediately submit then the position sizes would be modified as one intends.



          however, stop and target orders will not be calculated using the real world account entry prices. this can in turn be remedied using the chart trading functionality to move orders manually.



          i share this information for any other users in case anyone else would ever trade with real funds and want to make minuscule adjustments to the execution of automated strategies.





          as a side annotation, for some reason only the first 4 syncing account positions options are available for my strategies. the adopt account position is obvious and self explanatory enough that i would have tested it but as i mentioned, it is not available when enabling my strategies.

          Comment


            #6
            Hello rtwave,

            A strategy has to be programmed to be aware of the real-world account position in order to use Adopt account position.

            From the Help Guide on 'Adopt account position':

            "Note: Adopt account position will only be available if the developer of a strategy has programmed the strategy to be aware of the real-world account position. If this setting is not available when starting your strategy, the strategy was not programmed in a manner capable of handling account positions. If you are a developer and would like your strategy to handle a real world position, please see the following article here on these properties.​"

            HTML Code:
            https://ninjatrader.com/support/helpGuides/nt8/index.html?syncing_account_positions.htm#AdoptAccountPosition


            If you have any further questions, please let us know.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by argusthome, 03-08-2026, 10:06 AM
            0 responses
            88 views
            0 likes
            Last Post argusthome  
            Started by NabilKhattabi, 03-06-2026, 11:18 AM
            0 responses
            48 views
            0 likes
            Last Post NabilKhattabi  
            Started by Deep42, 03-06-2026, 12:28 AM
            0 responses
            30 views
            0 likes
            Last Post Deep42
            by Deep42
             
            Started by TheRealMorford, 03-05-2026, 06:15 PM
            0 responses
            34 views
            0 likes
            Last Post TheRealMorford  
            Started by Mindset, 02-28-2026, 06:16 AM
            0 responses
            68 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Working...
            X