UDAY_C_Santhakumar

UCS_Squeeze_Timing-V2

Statistically, Squeeze fires in the direction of strength (Up or Down). By replacing the Rate of Change with Bollinger Band % BB, allows us to easily pick the direction to trade the Squeeze. With the knowledge of Price Pattern, it makes it even easier.

I have identified 4 Setups that works wells with this. I will let you explore and comment. Could possibly initiate arguments and can identify a few more.

Nothing is perfect, but probable.

Using this with the Timing V1 Signals - It is easier to sneak in. More variations to this in future. Will need time to backtest other variations.

Uday C Santhakumar
开源脚本

本着真正的TradingView精神,该脚本的作者将其开源发布,以便交易者可以理解和验证它。为作者喝彩!您可以免费使用它,但在出版物中重复使用此代码受网站规则的约束。 您可以收藏它以在图表上使用。

免责声明

这些信息和出版物并不意味着也不构成TradingView提供或认可的金融、投资、交易或其它类型的建议或背书。请在使用条款阅读更多信息。

想在图表上使用此脚本?
// Variation - Lazybear Squeeze Indicator
// Recreated and Modified by UCSgears
// Replaced the momentum indicator 

study(shorttitle = "UCS_SQUEEZE_Timing_V2", title="Squeeze Momentum Timing and Direction", overlay=false)

lengthBB = input(20, title="BB Length")
multBB = input(2,title="BB MultFactor")
lengthKC=input(20, title="KC Length")
multKC = input(1.5, title="KC MultFactor")

useTrueRange = input(true, title="Use TrueRange (KC)", type=bool)

// Calculate BB
source = close
basis = sma(source, lengthBB)
dev = multBB * stdev(source, lengthBB)
upperBB = basis + dev
lowerBB = basis - dev

// Calculate KC
ma = sma(source, lengthKC)
range = useTrueRange ? tr : (high - low)
rangema = sma(range, lengthKC)
upperKC = ma + rangema * multKC
lowerKC = ma - rangema * multKC

sqzOn  = (lowerBB > lowerKC) and (upperBB < upperKC)
sqzOff = (lowerBB < lowerKC) and (upperBB > upperKC)
noSqz  = (sqzOn == false) and (sqzOff == false)

bbr = ((source - lowerBB)/(upperBB - lowerBB))-0.5

val = sma(bbr,20)

bcolor = iff( val > 0, 
            iff( val > nz(val[1]), green, blue),
            iff( val < nz(val[1]), red, orange))
scolor = noSqz ? blue : sqzOn ? red : green 
plot(val, color=bcolor, style=histogram, linewidth=3)
plot(0, color=scolor, style=circles, linewidth=3)