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

How to set parabolic/trailing stop strategy builder AND a time gap issue over night

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

    How to set parabolic/trailing stop strategy builder AND a time gap issue over night

    Hello....
    In the strategy builder. I am trying to figure out how to set up a moving stop. Basically, for example, let's say I have 100 tick profit target. I wan the stop to move to 25 when price reaches 50 ticks, then move to 50 ticks profit, when price moves to 75 ticks, then close out when price reaches 100. What exactly and where do I input that into the strategy builder?

    I have searched all the help sections for parabolic, if that is even what I need? Those instructions are just not complete enough. For example, under "Acceleration", it just says "this is the acceleration value". What does that mean? Same thing for "max acceleration". It is the "max" for the acceleration (which is never explained...i/e, what is it, what value should be used (.1,1,1000, who knows).

    I just want to move the stop in increments. Please tell me how to do that.

    AND I had a weird thing happen. I am running a LIVE strategy on the micro just to experiment. I put the computer to sleep when I leave the office every night. When I arrived this morning, the chart literally has NO candles or executions during the time the computer was put to sleep. Does that make sense? Even IF the computer being put to sleep paused the strategy (is that correct btw?), how would any of that affect the candle display?

    Thank you

    #2
    Hello Touch-Ups,

    Thank you for your post.

    One option available to you is to set a trailing stop, although this stop would trail with each tick of profit rather than adjusting for every 25 additional ticks in profit. A trailing stop is set to a specific value when the entry is filled, and then it will keep the same distance from the price and trail behind for each tick of profit. To achieve what you have described, you could use exit order methods and add logic in the Strategy Builder that modifies the price of the exit methods. It is important to note that you can not use exit methods in conjunction with any orders from the Stops and Targets window, which use Set() methods, per the internal order handling rules:

    https://ninjatrader.com/support/help...antedPositions

    There is an example created by my colleague Chelsea that uses the Strategy Builder to perform a breakeven movement on an ExitLongStopMarket order. You could utilize a similar approach that modifies the price of the Exit order when 50 ticks and 75 ticks of profit. The example may be found here:

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


    A parabolic stop would follow a formula to trail the stop loss, although the trailing is not in even increments. It would be in more of a parabolic motion where the higher the acceleration, the quicker the stop price would move toward the market price. Max acceleration could be thought of as hitting a maximum speed increase toward the price. There are also some ideas about the Parabolic SAR on this publicly available link that may help to understand how a Parabolic Stop would behave:

    https://www.thebalance.com/parabolic...rading-1031198

    In addition, my colleague Brandon has written a post that goes into further depth regarding how a Parabolic Stop works and how it is similar to the Parabolic SAR indicator:

    https://ninjatrader.com/support/foru...10#post1152610


    For NinjaTrader to receive data and run a live strategy, it must be open and connected. Typically, putting a computer into sleep mode disconnects the internet as well. Your chart would not be able to plot candles if it is not connected to your market data provider. Once NinjaTrader has connected to data again, you could right-click the chart and select "Reload all historical data" to fill in any missing candles. While running a strategy, there are certain behaviors that NinjaTrader can follow when the connection is lost. This setting may be found at Control Center > Tools > Options > Strategies > On connection loss. The options are keep running, recalculate, or stop strategy. A description of each may be found here:

    https://ninjatrader.com/support/help...riptProperties


    Please let us know if we may be of further assistance.
    Emily C.NinjaTrader Customer Service

    Comment


      #3
      Thank you very much for the reply! I will check out those links.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by RobotSyndicate, 07-16-2022, 06:28 AM
      2 responses
      57 views
      0 likes
      Last Post RobotSyndicate  
      Started by tarikmedjber, Today, 03:45 AM
      1 response
      22 views
      0 likes
      Last Post tarikmedjber  
      Started by ironwarriorsale, Today, 03:33 AM
      0 responses
      14 views
      0 likes
      Last Post ironwarriorsale  
      Started by ironwarriorsale, Today, 03:31 AM
      0 responses
      13 views
      0 likes
      Last Post ironwarriorsale  
      Started by ChainsawDR, Today, 02:36 AM
      0 responses
      20 views
      0 likes
      Last Post ChainsawDR  
      Working...
      X