First TTM Squeeze red bar after minimum of 3 red dots


Category:
0
0

Hi Pete,

I’m not sure if I missed it but I don’t see this question asked yet? I’m looking for a scan for stocks coming out of the squeeze on the bearish side.

Thanks again!

Marked as spam
Posted by (Questions: 8, Answers: 18)
Asked on August 20, 2022 10:16 pm
320 views
0
Private answer

Seems odd that I have no already covered every possible combination of TTM Squeeze patterns. This is one of the most popular indicators in this forum.

For the solution I am using some code from this previous solution which scans for the number of red dots:

https://www.hahn-tech.com/ans/ttm-squeeze-scan-that-looks-the-number-of-red-dots-in-a-row/

And to this I add a few additional lines to capture the first red histogram bar so long as there are at least 3 red dots on the center-line:

input price = CLOSE;
input length = 20;
input nK = 1.5;
input nBB = 2.0;
input alertLine = 1.0;
def squeezeDots = TTM_Squeeze(price, length, nK, nBB, alertLine).SqueezeAlert;
def squeezeHistogram = TTM_Squeeze(price, length, nK, nBB, alertLine).Histogram;
def alertCount = if squeezeDots[1] == 1 and squeezeDots == 0 then 1 else if squeezeDots == 0 then alertCount[1] + 1 else 0;
def redBar = squeezeHistogram < 0 and squeezeHistogram < squeezeHistogram[1]; def threeRedDots = alertCount >= 3;
plot scan = threeRedDots and redBar and !redBar[1];

Marked as spam
Posted by (Questions: 37, Answers: 4118)
Answered on August 21, 2022 4:53 pm
0
Thanks Pete! I was as shocked as you when I didn't see this question asked yet!
( at August 23, 2022 11:11 am)