Hello! This is pulled from the B4 indicator where he has a Squeeze dot print on the lower indicator. The coding of this particular style squeeze is new to me and I don't know how to convert this into a MTF. I make my entries on a 1m chart, but right now I have the 3m, 5m, and 10m up and manually looking at each chart just for the squeeze dot.
Thanks in advance!
Any help explaining the use of the "reference" would also be appreciated. Tried reading the TOS documentation and that just confused me more.
Thanks in advance!
Any help explaining the use of the "reference" would also be appreciated. Tried reading the TOS documentation and that just confused me more.
Code:
declare lower;
input MACDBB_FastLength = 12;
input MACDBB_SlowLength = 26;
input MACDBB_BandLength = 15;
#input MACDBB_NumDev = 1.0;
def MACDBB_Data = MACD(fastLength = MACDBB_FastLength, slowLength = MACDBB_SlowLength, MACDLength = 9);
def MACDBB_Upper = reference BollingerBands(price = MACDBB_Data, length = MACDBB_BandLength,
Num_Dev_Dn = -1, Num_Dev_Up = 1).UpperBand;
def MACDBB_Lower = reference BollingerBands(price = MACDBB_Data, length = MACDBB_BandLength,
Num_Dev_Dn = -1, Num_Dev_Up = 1).Lowerband;
### Squeeze
input SQZ_SqueezeLength = 30;
def SQZ_Bandwidth = MACDBB_Upper - MACDBB_Lower;
def SQZ_Squeeze_Low = Lowest(SQZ_Bandwidth, SQZ_SqueezeLength);
def SQZ_Squeeze = SQZ_Bandwidth == SQZ_Squeeze_Low;
plot SQZ_Dot = if SQZ_Squeeze then 0 else Double.NaN;
SQZ_Dot.SetPaintingStrategy(PaintingStrategy.POINTS);
SQZ_Dot.SetLineWeight(4);
SQZ_Dot.SetDefaultColor(Color.WHITE);
SQZ_Dot.HideTitle();
SQZ_Dot.HideBubble();
Last edited by a moderator: