Three Bar Reversal Pattern and Indicator for ThinkorSwim

BenTen

BenTen

Administrative
Staff
VIP
Warehouse
Three-bar reversal is a powerful pattern for day trading. The setup looks for a few consecutive red candlesticks and the final bar being a green candle closing higher than previous bars.

Here is an example:



Below is the code to identify bullish trigger bar in the Three Bar Reversal pattern. It also comes with an alert system.

thinkScript Code

Rich (BB code):
# Three-Bar Reversal Indicator
# Found in the thinkScript Archive
# Alert added by WalkingBallista
# https://usethinkscript.com/d/187-three-bar-reversal-pattern-and-indicator-for-thinkorswim

def TBRup = close > open[1] and close[1] < close[2]  and close[2] < close[3] and close[3] < close[4];
plot bullish = if TBRup then high else Double.NaN;
bullish.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_UP);
alert(bullish,"TBR Up", alert.Bar,sound.ding);

Shareable Link

http://tos.mx/pLfTyM

If you would like to look for bearish trigger bar in this pattern, you can insert the following code into that indicator.

Rich (BB code):
def TBRdown = close < open[1] and close[1] > close[2] and close[2] > close[3] and close[3] > close[4];
plot bearish = if TBRdown then low else Double.NaN;
bearish.SetPaintingStrategy(PaintingStrategy.BOOLEAN_ARROW_DOWN);
alert(bearish,"TBR Down", alert.Bar, sound.ding);
The script was posted on the thinkScript Lounge Archive. It did not mention who created the indicator.
 
Last edited:

Top