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

TrailBuiderExample's stop keeps moving away from price

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

    TrailBuiderExample's stop keeps moving away from price

    In my strategy after price went into positive territory the stop would move as it should, okay. Then as price came back down but instead of protecting or locking in my supposed profit, the stop kept running away from price back down into negative territory!

    It trades like I do, no discipline. I tend to move my stop hoping it goes back up, I suck at trading. But these strategies do the same thing!!

    I thought maybe I did something wrong in my complicated strategy, so I just used the out of the box Example TrailBuilderExample to see what it is supposed to do. It does the same thing.
    Instead of locking in profit it backs away from price as it approaches it. What is the sense?? If it won't lock in profit but back down into negative territory I might as well, go back to trading the I always do! Scared. lol

    Is there a way to make the example or mine to stay put once I have locked in a little profit? And not give it all back.

    #2
    Hello trdninstyle,

    Thanks for your post.

    When running the TrailBuilderExample script from the forum thread linked below, I see that an initial entry order and stop loss are placed. When the market price moves up a certain number of ticks in our favor, the stop-loss trails upward. When the market price moves against our favor, the stop loss remains in the same position until the stop loss order is filled.

    TrailBuilderExample: https://ninjatrader.com/support/foru...596#post806596

    See this demonstration video showing the behavior that is explained above: https://brandonh-ninjatrader.tinytak...OV8yMDY4MjQ4NA

    Please test the TrailBuilderExample from the forum thread linked above using the same steps and settings seen in the demonstration video. Do you see a different behavior occurring?

    ​​​​​​​Let me know if I may assist you further.
    Brandon H.NinjaTrader Customer Service

    Comment


      #3
      Hello Brandon,

      It's still doing that, tho. I made a video but ended up being 15 minutes. I do like the 30 second chart, I might stay with that, especially if thats what works. I'll trade standing on my head if it will work.

      I'll re download the example just in case I tweaked it somewhere along the way. I did have the bid -3 ticks, so I don't get that error.

      This is a 1-minute video showing the settings. Because of the volatility at the end, it errored.

      Free online storage and sharing with Screencast.com. 2 GB of storage and 2 GB of bandwidth per month for free. We won't compress, alter or take ownership of your content.


      But the stop moved away from price after I was in profit, all the way back to breakeven. I didn't keep it going to see if it would go into negative territory, probably would have.

      Let me go re-download it, maybe thats it? But I can get this to work right do u think?

      I remember your advice from before for that other thing, I'm going to double back to it later.
      In section two.

      Stop order can't be placed above the bid - NinjaTrader Support Forum
      Attached Files
      Last edited by trdninstyle; 12-14-2022, 01:33 PM.

      Comment


        #4
        I re-downloaded it. The stop now gets taken out. Now I can go from here.

        Thanks

        Comment


          #5
          I took the trail builder example, since I know the trailing stop won't move after it's in profit and added a bull bar for a condition. And I changed the entry to a limit order.
          Do I need to add a variable for the limit order? Because it's minus 2 ticks let's say, I know an input would be -2 and -999 in the input section.

          And in set 2 would I remove State = State. Realtime or keep it there? Set 3 I don't believe I need to do anything there.
          I copied the original and made it AaTrailBuilderExample.




          Click image for larger version

Name:	2022-12-14 18_46_52-2022_12_14_18_43_07_Chart_MES_03_23.png
Views:	189
Size:	38.2 KB
ID:	1227610Click image for larger version

Name:	2022-12-14 18_49_27-2022_12_14_18_47_30_Chart_MES_03_23.png
Views:	132
Size:	35.8 KB
ID:	1227611Click image for larger version

Name:	2022-12-14 19_10_14-2022_12_14_19_09_18_Strategy_Builder.png
Views:	136
Size:	31.0 KB
ID:	1227612Click image for larger version

Name:	2022-12-14 19_11_03-2022_12_14_19_10_29_Chart_MES_03_23.png
Views:	132
Size:	31.2 KB
ID:	1227613

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Karado58, 11-26-2012, 02:57 PM
          8 responses
          14,828 views
          0 likes
          Last Post Option Whisperer  
          Started by Option Whisperer, Today, 09:05 AM
          0 responses
          1 view
          0 likes
          Last Post Option Whisperer  
          Started by cre8able, Yesterday, 01:16 PM
          3 responses
          11 views
          0 likes
          Last Post cre8able  
          Started by Harry, 05-02-2018, 01:54 PM
          10 responses
          3,204 views
          0 likes
          Last Post tharton3  
          Started by ChartTourist, Today, 08:22 AM
          0 responses
          6 views
          0 likes
          Last Post ChartTourist  
          Working...
          X