OPEN-SOURCE SCRIPT
CAHOLD / CBLOHD

CAHOLD (Close Above Highest Low Day) and CBLOHD (Close Below Lowest High Day)
The logic is based on identifying pullbacks followed by strength in the direction of the trend, making it useful as a trend-continuation entry signal rather than a reversal tool.
⸻
How CAHOLD Works (Bullish)
1. A sequence of red candles forms (a pullback).
2. The first green candle appears.
3. The script identifies the highest high of the prior red-candle sequence (HOLD).
4. A CAHOLD signal triggers when a green candle closes above that HOLD level.
5. A small green arrow is plotted below the candle.
⸻
How CBLOHD Works (Bearish)
1. A sequence of green candles forms (a bounce).
2. The first red candle appears.
3. The script identifies the lowest low of the prior green-candle sequence (LOHD).
4. A CBLOHD signal triggers when a red candle closes below that LOHD level.
5. A small red arrow is plotted above the candle.
⸻
Optional Filters
• EMA / SMA Trend Filter
Only shows CAHOLDs in uptrends and CBLOHDs in downtrends.
• Minimum Pullback Depth
Requires a minimum number of red/green candles before a signal can trigger.
• ATR Breakout Filter
Requires price to break the level by a volatility-adjusted amount.
The logic is based on identifying pullbacks followed by strength in the direction of the trend, making it useful as a trend-continuation entry signal rather than a reversal tool.
⸻
How CAHOLD Works (Bullish)
1. A sequence of red candles forms (a pullback).
2. The first green candle appears.
3. The script identifies the highest high of the prior red-candle sequence (HOLD).
4. A CAHOLD signal triggers when a green candle closes above that HOLD level.
5. A small green arrow is plotted below the candle.
⸻
How CBLOHD Works (Bearish)
1. A sequence of green candles forms (a bounce).
2. The first red candle appears.
3. The script identifies the lowest low of the prior green-candle sequence (LOHD).
4. A CBLOHD signal triggers when a red candle closes below that LOHD level.
5. A small red arrow is plotted above the candle.
⸻
Optional Filters
• EMA / SMA Trend Filter
Only shows CAHOLDs in uptrends and CBLOHDs in downtrends.
• Minimum Pullback Depth
Requires a minimum number of red/green candles before a signal can trigger.
• ATR Breakout Filter
Requires price to break the level by a volatility-adjusted amount.
Script de código aberto
Em verdadeiro espírito do TradingView, o criador deste script o tornou de código aberto, para que os traders possam revisar e verificar sua funcionalidade. Parabéns ao autor! Embora você possa usá-lo gratuitamente, lembre-se de que a republicação do código está sujeita às nossas Regras da Casa.
Aviso legal
As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.
Script de código aberto
Em verdadeiro espírito do TradingView, o criador deste script o tornou de código aberto, para que os traders possam revisar e verificar sua funcionalidade. Parabéns ao autor! Embora você possa usá-lo gratuitamente, lembre-se de que a republicação do código está sujeita às nossas Regras da Casa.
Aviso legal
As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.