Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Initiate a reverse trade when stopped out

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

    Initiate a reverse trade when stopped out

    Can anyone please tell me if there is a way to set up the conditions in the Strategy Wizard so that when the current trade is stopped out a trade in the opposite direction is entered?

    ie: The triggering of the stop loss is the condition required to enter the next trade.

    There is sure to be a post already in the forum, but I can't find it (if it is here).
    Thanks.

    #2
    alanterry,

    How are you stopping out of your position? If you are explicitly coming up with some number to exit at instead you can just submit an EnterShort() order. That will automatically close the long position and buy a short position for you.
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      Initiate a reverse trade when stopped out

      Thanks Josh.
      I want to change direction at a stop loss that has been set as a certain number of ticks. I have been setting this on the "Stops and targets" screen of the Strategy Wizard. I can't work out how to do what you suggest.

      Comment


        #4
        alanterry,

        Instead of using that Stops & Targets page please try this instead. Go back to the Conditions & Actions page and then create a simple condition that checks the Close price vs your average entry price. Offset the entry price by the ticks you want your stop loss to be, then as your action just tell it to do EnterShort().

        When price touches your avg entry price + offset ticks that means your stop was reached, and submitting the short would close your long (like a stop loss) and reverse you into a short position.
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          Initiate a reverse trade when stopped out

          Getting better! Really appreciate your comments.

          Is there a way that I can limit the reversal to just ONE time, and after that have the normal system entries resume?

          Comment


            #6
            alanterry,

            Sure. Limit your first set of orders by a User Variable. Check that a User Variable equals 0 before entering. Once entered set that equal to 1. When you do this that set will never execute again.

            Then for your reentries just create a new set without this limitation.
            Josh P.NinjaTrader Customer Service

            Comment


              #7
              Initiate a reverse trade when stopped out

              Josh,

              Nearly there, I suspect!! (And learning heaps in the process.)

              The only trouble now is that the losing trades keep on repeating until there is a winning trade, which stops the sequence.

              Can I stop this sequence after two losing trades?

              Comment


                #8
                You will want to use the sections inside the Strategy category to capture the PnL. Then you can increase another User Variable each time it is a losing trade. When the User Variable reaches 2, don't trade any more.
                Josh P.NinjaTrader Customer Service

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                0 responses
                647 views
                0 likes
                Last Post Geovanny Suaza  
                Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                0 responses
                367 views
                1 like
                Last Post Geovanny Suaza  
                Started by Mindset, 02-09-2026, 11:44 AM
                0 responses
                108 views
                0 likes
                Last Post Mindset
                by Mindset
                 
                Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                0 responses
                571 views
                1 like
                Last Post Geovanny Suaza  
                Started by RFrosty, 01-28-2026, 06:49 PM
                0 responses
                573 views
                1 like
                Last Post RFrosty
                by RFrosty
                 
                Working...
                X