Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How to Plot a Dot 50 BarsAgo

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

    How to Plot a Dot 50 BarsAgo

    I’m new to NT & haven’t done any programming for a long time. Any assistance would be greatly appreciated on how to get a Dot plot on a chart 50bars ago. I’ve searched the forum & below is the best bit of code I’ve been able to come up with so far - which still only puts a dot below the most recently completed bar instead of 50 bars ago.

    {
    DrawDot("tag1", 50, Low[50] - TickSize, Color.Red);
    }


    From the draw DrawDot reference Page I thought putting 50, Low[50] would move the Dot back 50 bars but that doesn’t it.


    I also tried: DrawDot(CurentBar.ToString() +"tag1", 0, - TickSize, Colre.Red); which put a dot under every bar.

    (I won’t mention all the many other things I tried that didn’t work )

    Thanks for any suggestions.

    Rob.

    #2
    That will work. Make sure you do something more like:

    if (CurrentBar > 50)
    DrawDot("Tag1", 50, Low[50], Color.Red);
    RayNinjaTrader Customer Service

    Comment


      #3
      Adding the "If (CurrentBar > 50)" makes it work fine.

      Thanks for the quick reply Ray,

      Rob

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Hwop38, 05-04-2026, 07:02 PM
      0 responses
      164 views
      0 likes
      Last Post Hwop38
      by Hwop38
       
      Started by CaptainJack, 04-24-2026, 11:07 PM
      0 responses
      318 views
      0 likes
      Last Post CaptainJack  
      Started by Mindset, 04-21-2026, 06:46 AM
      0 responses
      246 views
      0 likes
      Last Post Mindset
      by Mindset
       
      Started by M4ndoo, 04-20-2026, 05:21 PM
      0 responses
      350 views
      0 likes
      Last Post M4ndoo
      by M4ndoo
       
      Started by M4ndoo, 04-19-2026, 05:54 PM
      0 responses
      179 views
      0 likes
      Last Post M4ndoo
      by M4ndoo
       
      Working...
      X