Climactic Bar

From BPAX Lab

Climatic Bars in Micro-Channels often leads to pauses or PBs that can usually give at least a scalp, especially if it shows up late in a trend, such as leg3 leg4. If it shows early in a trend, it can signal a potential PB, swing trader should sit tight and allow the PBs to do their things first.

//@version=5
indicator("Climatic Bars", shorttitle="Clx-Bars",overlay = true)

//Eliminate climatic bars with extensive tails
bar_range = high - low
IBS = (close -low) / bar_range


inside_bar = high <= high[1] and low >= low[1]
bull_breakout = high > high[1]
bear_breakout = low < low[1]
outside_bar = bull_breakout and bear_breakout


bull_climax_bar = IBS > 0.66 and not inside_bar[1] and not outside_bar and (low >= low[1] and low[1] >= low[2] and bull_breakout and (high - high[1] > 3.0 * (low - low[1])))

bear_climax_bar = IBS < 0.33 and not inside_bar[1] and not outside_bar and (high <= high[1] and high[1] <= high[2] and bear_breakout and (low[1] - low > 3.0 * (high[1] - high)))


barcolor(bull_climax_bar ? color.green : na)
plot(bull_climax_bar ? high + 5 : na, color = color.green, style = plot.style_cross)


barcolor(bear_climax_bar ? color.red : na)
plot(bear_climax_bar ? low - 5 : na, color = color.red, style = plot.style_cross)