Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

count-bars

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

    count-bars

    Hello,

    I´d like to count how many bars have been plotted after a certain condition was filled. And I would like to show the "current" number above the bar. I don´t know how I could do this.

    Thanks for any help.

    Best regards
    Tony

    #2
    Hi tonynt,

    You can capture CurrentBar at the time of the condition, and compare this captured value to current bar to get the bars since your condition. This works very similar to the RemoveDraw thread you started:


    You can DrawText() for the difference between CurrentBar and the captured CurrentBar value from the condition.
    Ryan M.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    61 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    40 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    21 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    23 views
    0 likes
    Last Post TheRealMorford  
    Started by Mindset, 02-28-2026, 06:16 AM
    0 responses
    51 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Working...
    X