The support forum is built with (1) General and FAQ forums for common trading queries received from aspiring and experienced traders, and (2) forums for course video topics. How to Trade Price Action and How to Trade Forex Price Action videos are consolidated into common forums.
Brooks Trading Course social media communities
Notifications
Clear all
Programming & Automation
2
Posts
2
Usuários
2
Reactions
1,677
Visualizações
Topic starter
17/06/2023 11:12 am
//@version=5 indicator("18-bar Range", overlay = true) var float rangeHigh = 0 var float rangeLow = 0 var box myBox = na newDay = ta.change(time("D")) barsCount = ta.barssince(newDay) if (barsCount == 0) rangeHigh := -9999999 rangeLow := 9999999 if (barsCount > 0 and barsCount < 18) if (high > rangeHigh) rangeHigh := high if (low < rangeLow) rangeLow := low if (barsCount == 17) myBox := box.new(left = bar_index + 1, top = rangeHigh, right = bar_index, bottom = rangeLow, border_color = color.new(#74aa74, 90), bgcolor = color.new(#cce2cc, 80)) if barsCount >= 17 myBox.set_right(bar_index)
17/06/2023 2:56 pm
Thanks PB.