Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Stops not working as expected

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

    Stops not working as expected

    i have a system that has 2 buy Sets. Buy Long for Entry L and Entry L2 and one Exit Set. Sell order for Entry L and L2.

    i have stop condition for Entry L and L2
    Even a stop condition for the entire position.
    The stops use the Currency setting.

    Please advise





    Attached Files

    #2
    Hello hdge4u,

    Thanks for your post and screenshots.

    The XL exits would be controlled by your strategy logic, can you confirm that these exits are working as expected?

    What is the strategy's "calculate" setting (Calculate.OnBarClose, Calculate.OnPriceChange, Calculate.OnEachTick)?

    When you run your strategy, do you see any errors listed in the NinjaTrader control center's "Log" tab?

    I would suggest removing the "named" stoploss exits and just use the single stoploss with no signal name and retest.

    Comment


      #3

      The XL exits would be controlled by your strategy logic, can you confirm that these exits are working as expected? Exits work as expected. Screen Shots show this.

      What is the strategy's "calculate" setting (Calculate.OnBarClose, Calculate.OnPriceChange, Calculate.OnEachTick)? on each tick

      When you run your strategy, do you see any errors listed in the NinjaTrader control center's "Log" tab? no errors found. Trace Log Needed?

      I would suggest removing the "named" stoploss exits and just use the single stoploss with no signal name and retest. ? do you mean to hard code the number instead of using the Input named "Stop"

      Comment


        #4
        Hello hdge4u,

        Thanks for your reply.

        You have created 3 SetStopLoss() , remove the two that are tied to signals L and L2, and test again with just the one SetStopLoss().

        Comment


          #5
          I set the stop loss for the entire position, ran the playback, and there were no losses in excess of the $500 parameter.
          Trade blotter attached.
          Attached Files

          Comment


            #6
            Entry L is not adhering to the stop parameter when both the input "stop" and $500 hard code is used.
            Attached Files

            Comment


              #7
              Hello hdge4u,

              Thanks for your reply.

              Please attach the strategy builder strategy file for review. The file can be found in Documents>NinjaTrader8>bin>Custom>Strategies> and will be the .cs file type.

              If you would prefer not to post your strategy, you are welcome to write into ScriptingSupport[at]NinjaTrader[dot]com, mark the e-mail subject atten: Paul and Ticket#3028211. In the body of the e-mail include a link to this thread and attach your file there.

              Comment


                #8
                let's troubleshoot this a bit more.

                For what it's worth, i loaded up the L2 conditions from another strategy and pasted it into the builder, could that be an issue?

                Should i just rewrite the strategy, it's not that complicated?

                Comment


                  #9
                  Hello hdge4u,

                  Thanks for your reply.

                  I would not be able to answer without seeing the data.

                  If it does not take that much time go ahead and create new.

                  Comment


                    #10
                    would entries per direction have anything to do with this? Currently have 1 entry per direction and all entries handling.

                    Comment


                      #11
                      Hello hdge4u,

                      Thanks for your reply.

                      The entries per direction and entry handling relate to the Entries. With entries per direction set to 1 and entry handling set to all entries, the strategy could only allow a single entry per direction and all other entries would be ignored (meaning the order is not placed). This would mean you could have an "L" or "L2" entry but not both while one or the other is active.
                      References:



                      These would not relate to a stop not working as expected.

                      Comment


                        #12
                        see attached strategy that is not adering to the stops
                        Attached Files

                        Comment


                          #13
                          Hello hdge4u,

                          Thanks for your reply.

                          Your strategy has the "exit on session close" turned off and you are using a TimeInForce setting of Day.

                          What is happening is that when you have a position that is not closed by the end of the day has its stop canceled by the time in force setting of Day.

                          Please change the setting to GTC.

                          Comment


                            #14
                            thanks. that fixed it.

                            Comment

                            Latest Posts

                            Collapse

                            Topics Statistics Last Post
                            Started by NullPointStrategies, Yesterday, 05:17 AM
                            0 responses
                            62 views
                            0 likes
                            Last Post NullPointStrategies  
                            Started by argusthome, 03-08-2026, 10:06 AM
                            0 responses
                            134 views
                            0 likes
                            Last Post argusthome  
                            Started by NabilKhattabi, 03-06-2026, 11:18 AM
                            0 responses
                            75 views
                            0 likes
                            Last Post NabilKhattabi  
                            Started by Deep42, 03-06-2026, 12:28 AM
                            0 responses
                            45 views
                            0 likes
                            Last Post Deep42
                            by Deep42
                             
                            Started by TheRealMorford, 03-05-2026, 06:15 PM
                            0 responses
                            50 views
                            0 likes
                            Last Post TheRealMorford  
                            Working...
                            X