• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Displacing Plots by various amounts

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

    Displacing Plots by various amounts

    Hello,

    I have 3 plots on my indicator for example:

    Values[2][0] = SMA(200)[0];
    Values[3][0] = SMA(100)[0];
    Values[4][0] = SMA(50)[0];

    I want to displace all of these to the right on the chart. (move it in the future).

    How can i code this to make it move over to the right different values.

    For example, i want to displace the first one by 8 bars and the second one by 5 bars and the third one by 3 bars.


    I tried changing the plot to something like SMA(200)[-8] but that doesn't work and it doesn't plot.

    Thank you in advance.

    #2
    Hello priceisking,

    Thanks for your post.

    All I can find is the Displacement property but that would apply to all plots of the indicator: https://ninjatrader.com/support/help...splacement.htm

    If breaking it up into 3 separate indicators is not an option, then all I could suggest is using OnRender() for custom drawing. You can take a look at the indicator IchimokuCloud available in the user apps for an idea on the coding required..
    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Ok Thank you!

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Harvard, Yesterday, 11:37 PM
      0 responses
      14 views
      0 likes
      Last Post Harvard
      by Harvard
       
      Started by Mebjan, Yesterday, 08:52 PM
      2 responses
      13 views
      0 likes
      Last Post NinjaTrader_Marco  
      Started by authenticx, Yesterday, 10:07 PM
      0 responses
      13 views
      0 likes
      Last Post authenticx  
      Started by Hurrikane, Yesterday, 09:18 PM
      0 responses
      9 views
      0 likes
      Last Post Hurrikane  
      Started by Fness2020, Yesterday, 08:29 PM
      0 responses
      18 views
      0 likes
      Last Post Fness2020  
      Working...
      X