Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Auto updating Path Drawing throughout entire CME ETH trading session

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

    Auto updating Path Drawing throughout entire CME ETH trading session

    Hello, Just looking for a bit of advice on how to tackle this problem,

    I would like to create an indicator that just draws a Path Drawing that starts from the first bar of a session and ends at the last bar of the session. Essentially I would like to only connect Highs and Lows. I have attached a photo of how I would like the finished product to look.

    The purple version shows how the points of the path will move as the bas are printing live but the blue version shows what the finished product should look like. The second bar in the series has to print with either a Higher High(HH) & Low(HL) or a Lower High(LH) & Low(LL) compared to the first bar to place the first point. If it is not achieved, the first point will not be placed until it happens. In these examples, the path starts by going down. The first point is made when the bar makes its first LH & LL in Bar [62]. The next bar must only have a LL to continue the trend regardless if it also has a HH, these conditions only move the point. These examples can be seen in bars [63], [67] & [69]. The only way the line reverses, in which case a new point is formed, is if a HH & HL appears as shown in bars [64], [66], [74], [80], [88], [91], [5] , [15], or a LH & LL seen in bars [65], [71], [75], [84], [89], [3], [12]. A point will not be moved or created if the current Bar's H & L finishes between the prev. Bar's H & L as seen in bars [81], [82], [6], [7], [8]. A new drawing will always begin at the start of the trading session.

    Some advice, or examples on how to approach creating an automatically updating drawing on screen, specifically with the Path drawing tool would be greatly appreciated.​

    #2
    Hello Don22Trader1,

    Thanks for your post.

    You could use the Draw.PathTool() method similar to the sample code in the help guide page.

    Draw.PathTool(): https://ninjatrader.com/support/help...pathtool().htm

    The Draw.PathTool() method takes a list of anchors. You would define what anchor points you want to use and then make a list of those anchors to draw the object on the chart.

    This method may not be entirely efficient if it is being updated for every bar since internally Draw.PathTool() uses PathGeometry. That said, you could try it out to see if this method suits your overall goals. It has likely been optimized since it is only using 1 object to render the path.

    Please let me know if I may assist further.
    <span class="name">Brandon H.</span><span class="title">NinjaTrader Customer Service</span><iframe name="sig" id="sigFrame" src="/support/forum/core/clientscript/Signature/signature.php" frameborder="0" border="0" cellspacing="0" style="border-style: none;width: 100%; height: 120px;"></iframe>

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    626 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    359 views
    1 like
    Last Post Geovanny Suaza  
    Started by Mindset, 02-09-2026, 11:44 AM
    0 responses
    105 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
    0 responses
    562 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    567 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X