Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Previous candle's low or high for a trailed stop loss without coding?

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

    Previous candle's low or high for a trailed stop loss without coding?

    Hi, I've read several posts about trailing a stoploss behind a previous candle, but none of them explain how this can be done using the Strategy Builder. I do not know how to code. I'm hoping there is a simple way to add this type of trailing stoploss to the strategies I can build easily in the Strategy Builder..
    Thanks for any suggestions!

    #2
    Hello traderbot,

    Thanks for your post.

    There is not a simple way to do this in the Strategy Builder but it can be done. What makes it a bit complicated is that you have to work within the limitations of the Strategy Builder which limits how things can be done when you don't want to use the built-in trailing stop.

    If I understand correctly you are looking to move a stop loss based on the prior bar.

    To do this you would need to use other exit methods as found in the "Order Management" folder of the "do the following" part of a set. For a stop loss you would need to use an appropriate stop exit order such as "exit long position by a stop order". Please note that when using these types of orders you would also need to replace your profit target with another exit order such as "exit long position by a limit order". In both cases, you would need to provide the specific price that you want these orders placed at.

    When using limit or stop type orders, in the Strategy Builder, you need to be aware that these orders are automatically canceled if they are not filled on the bar they are submitted. So this means that on each bar while in a position the strategy has to resubmit the order.

    What you can do is to create your entry conditions and when true have the set place your entry order and save your price target into a double type variable (that you would need to create). In another set, you would check that you are in a market position (long or short) and the action would be to submit your stop at the level of the prior bar and target orders at the price level previously saved. While you are in position the orders are resubmitted on each bar and the stop will be updated because the bars change and the profit target will remain at the value of the saved variable.

    Here are the educational resource available on the strategy builder:
    Free live webinar every other Thursday at 4:00 PM EST, through this link to all webinars: https://ninjatrader.com/PlatformTraining
    Previous recording of the Strategy Builder 301 webinar: https://youtu.be/HCyt90GAs9k?list=PL...auWXkWe0Nf&t=2
    Help guide for the strategy builder: https://ninjatrader.com/support/help...gy_builder.htm

    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Thank you! I didn't understand very much of your response, but I'll spend some more time learning about it all. The Thursday webinars sound like a great resource for additional help.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by RT001, Yesterday, 03:47 PM
      3 responses
      26 views
      0 likes
      Last Post NinjaTrader_Jim  
      Started by johnMoss, Yesterday, 10:40 PM
      1 response
      10 views
      0 likes
      Last Post NinjaTrader_Jesse  
      Started by torch2k, Today, 06:24 AM
      1 response
      6 views
      0 likes
      Last Post NinjaTrader_ChelseaB  
      Started by WalterSkinner, Yesterday, 02:37 PM
      4 responses
      23 views
      0 likes
      Last Post WalterSkinner  
      Started by Fer123, Yesterday, 04:57 PM
      1 response
      9 views
      0 likes
      Last Post NinjaTrader_Jim  
      Working...
      X