tjlizwelicha
Active member
"Created new reversal alert buy(gray points) and take profit (red points). "
Thank you. Is this for the Day Only or the Week Only?
Thank you. Is this for the Day Only or the Week Only?
#Confirmation Candles MTF Channel Label.
#Thank @cos251 for this RSM_MTF_Labels code used to make this.
input period = AggregationPeriod.DAY;
DefineGlobalColor("UpTrend", Color.Green);
DefineGlobalColor("DownTrend", Color.RED);
DefineGlobalColor("NoTrend", Color.GRAY);
script CC_ {
input aP = AggregationPeriod.DAY;
#Keltner Channel
def displace = 0;
def factorK = 2.0;
def lengthK = 20;
def price = close(period = ap);
input averageType = AverageType.SIMPLE;
def trueRangeAverageType = AverageType.SIMPLE;
def BulgeLengthK = 150;
def SqueezeLengthK = 150;
def BulgeLengthK2 = 40;
def SqueezeLengthK2 = 40;
def BulgeLengthPrice = 75;
def SqueezeLengthPrice = 75;
def BulgeLengthPrice2 = 20;
def SqueezeLengthPrice2 = 20;
def shift = factorK * MovingAverage(trueRangeAverageType, TrueRange(high(period = ap), close(period = ap), low(period = ap)), lengthK);
def averageK = MovingAverage(averageType, price, lengthK);
def AvgK = averageK[-displace];
def Upper_BandK = averageK[-displace] + shift[-displace];
def Lower_BandK = averageK[-displace] - shift[-displace];
def conditionK1 = price >= Upper_BandK;
def conditionK2 = (Upper_BandK[1] < Upper_BandK) and (Lower_BandK[1] < Lower_BandK);
def conditionK2L = (Upper_BandK[2] < Upper_BandK[1]) and (Lower_BandK[2] < Lower_BandK[1]);
def conditionK3L = (Upper_BandK[3] < Upper_BandK[2]) and (Lower_BandK[3] < Lower_BandK[2]);
def conditionK3 = (Upper_BandK[1] > Upper_BandK) and (Lower_BandK[1] > Lower_BandK);
def BandwidthK = (Upper_BandK - Lower_BandK) / AvgK * 100;
def condition_BWKUP = BandwidthK[1] < BandwidthK;
def condition_BWKDOWN = BandwidthK[1] > BandwidthK;
def BulgeK = Highest(BandwidthK, BulgeLengthK);
def SqueezeK = Lowest(BandwidthK, SqueezeLengthK);
def BulgeK2 = Highest(BandwidthK, BulgeLengthK2);
def SqueezeK2 = Lowest(BandwidthK, SqueezeLengthK2);
#################################################################
########## Trend & Labels #########
#################################################################
def UpTrend_ = (Upper_BandK[1] < Upper_BandK) and (Lower_BandK[1] < Lower_BandK);
def DownTrend_ = (Upper_BandK[1] > Upper_BandK) and (Lower_BandK[1] > Lower_BandK);
plot Trend_ = if UpTrend_ then 1 else if DownTrend_ then 0 else -1;
}
def currentPeriod = GetAggregationPeriod();
def CC;
if period >= currentPeriod {
CC = CC_(aP = period);
} else {
CC = Double.NaN;
}
AddLabel(!IsNaN(CC), if period == AggregationPeriod.MONTH then "M"
else if period == AggregationPeriod.WEEK then "W"
else if period == AggregationPeriod.FOUR_DAYS then "4D"
else if period == AggregationPeriod.THREE_DAYS then "3D"
else if period == AggregationPeriod.TWO_DAYS then "2D"
else if period == AggregationPeriod.DAY then "D"
else if period == AggregationPeriod.FOUR_HOURS then "4H"
else if period == AggregationPeriod.TWO_HOURS then "2H"
else if period == AggregationPeriod.HOUR then "60m"
else if period == AggregationPeriod.THIRTY_MIN then "30m"
else if period == AggregationPeriod.TWENTY_MIN then "20m"
else if period == AggregationPeriod.FIFTEEN_MIN then "15m"
else if period == AggregationPeriod.TEN_MIN then "10m"
else if period == AggregationPeriod.FIVE_MIN then "5m"
else if period == AggregationPeriod.FOUR_MIN then "4m"
else if period == AggregationPeriod.THREE_MIN then "3m"
else if period == AggregationPeriod.TWO_MIN then "2m"
else if period == AggregationPeriod.MIN then "1m"
else "", if CC == 1 then GlobalColor("UpTrend") else if CC == 0 then GlobalColor("DownTrend") else GlobalColor("NoTrend"));
Nice work!Confirmation Candels MTF labels of the channel color.
Thank @cos251 for this RSM_MTF_Labels code used to make this and @Christopher84 for this indicator.
Code:#Confirmation Candles MTF Channel Label. #Thank @cos251 for this RSM_MTF_Labels code used to make this. input period = AggregationPeriod.DAY; DefineGlobalColor("UpTrend", Color.Green); DefineGlobalColor("DownTrend", Color.RED); DefineGlobalColor("NoTrend", Color.GRAY); script CC_ { input aP = AggregationPeriod.DAY; #Keltner Channel def displace = 0; def factorK = 2.0; def lengthK = 20; def price = close(period = ap); input averageType = AverageType.SIMPLE; def trueRangeAverageType = AverageType.SIMPLE; def BulgeLengthK = 150; def SqueezeLengthK = 150; def BulgeLengthK2 = 40; def SqueezeLengthK2 = 40; def BulgeLengthPrice = 75; def SqueezeLengthPrice = 75; def BulgeLengthPrice2 = 20; def SqueezeLengthPrice2 = 20; def shift = factorK * MovingAverage(trueRangeAverageType, TrueRange(high(period = ap), close(period = ap), low(period = ap)), lengthK); def averageK = MovingAverage(averageType, price, lengthK); def AvgK = averageK[-displace]; def Upper_BandK = averageK[-displace] + shift[-displace]; def Lower_BandK = averageK[-displace] - shift[-displace]; def conditionK1 = price >= Upper_BandK; def conditionK2 = (Upper_BandK[1] < Upper_BandK) and (Lower_BandK[1] < Lower_BandK); def conditionK2L = (Upper_BandK[2] < Upper_BandK[1]) and (Lower_BandK[2] < Lower_BandK[1]); def conditionK3L = (Upper_BandK[3] < Upper_BandK[2]) and (Lower_BandK[3] < Lower_BandK[2]); def conditionK3 = (Upper_BandK[1] > Upper_BandK) and (Lower_BandK[1] > Lower_BandK); def BandwidthK = (Upper_BandK - Lower_BandK) / AvgK * 100; def condition_BWKUP = BandwidthK[1] < BandwidthK; def condition_BWKDOWN = BandwidthK[1] > BandwidthK; def BulgeK = Highest(BandwidthK, BulgeLengthK); def SqueezeK = Lowest(BandwidthK, SqueezeLengthK); def BulgeK2 = Highest(BandwidthK, BulgeLengthK2); def SqueezeK2 = Lowest(BandwidthK, SqueezeLengthK2); ################################################################# ########## Trend & Labels ######### ################################################################# def UpTrend_ = (Upper_BandK[1] < Upper_BandK) and (Lower_BandK[1] < Lower_BandK); def DownTrend_ = (Upper_BandK[1] > Upper_BandK) and (Lower_BandK[1] > Lower_BandK); plot Trend_ = if UpTrend_ then 1 else if DownTrend_ then 0 else -1; } def currentPeriod = GetAggregationPeriod(); def CC; if period >= currentPeriod { CC = CC_(aP = period); } else { CC = Double.NaN; } AddLabel(!IsNaN(CC), if period == AggregationPeriod.MONTH then "M" else if period == AggregationPeriod.WEEK then "W" else if period == AggregationPeriod.FOUR_DAYS then "4D" else if period == AggregationPeriod.THREE_DAYS then "3D" else if period == AggregationPeriod.TWO_DAYS then "2D" else if period == AggregationPeriod.DAY then "D" else if period == AggregationPeriod.FOUR_HOURS then "4H" else if period == AggregationPeriod.TWO_HOURS then "2H" else if period == AggregationPeriod.HOUR then "60m" else if period == AggregationPeriod.THIRTY_MIN then "30m" else if period == AggregationPeriod.TWENTY_MIN then "20m" else if period == AggregationPeriod.FIFTEEN_MIN then "15m" else if period == AggregationPeriod.TEN_MIN then "10m" else if period == AggregationPeriod.FIVE_MIN then "5m" else if period == AggregationPeriod.FOUR_MIN then "4m" else if period == AggregationPeriod.THREE_MIN then "3m" else if period == AggregationPeriod.TWO_MIN then "2m" else if period == AggregationPeriod.MIN then "1m" else "", if CC == 1 then GlobalColor("UpTrend") else if CC == 0 then GlobalColor("DownTrend") else GlobalColor("NoTrend"));
Looks like the KeltnerDon't mean to be critical, but I'm confused by the MTF labels, @Fluideng. Which channel? Bulge and squeeze prices? Keltner?
Thanks, Christopher!Looks like the Keltner
Yes it is the Keltner Channel with same settings as the Confirmation Candles.Thanks, Christopher!
Awesome play! Just flat out awesome!@Christopher84, this morning your cloud combos (15, 30, 60 min) gave me an entry earlier than my old method. Negative numbers on your consensus label gave me confidence to stay in when I took a little heat. I'm so grateful that you shared this with us! I still can't believe I'm plotting clouds!
@diamondhands, to see more than one label, it's necessary to add the indicator more than once. For example, if you're on a 5 min chart and you want to see a 5 min and 30 min label, you need to add the indicator twice and select a 5 min aggregation for one and a 30 min for the other. Also, the indicator will not display labels for a lower timeframe. If you're on a 5 min chart, a 3 min label will not display.Hello, Not all the MTF labels are showing, only the selected timeframe and if on that particular timeframe, the MTF label shows. Is there any setting which i am missing ?
Thanks for the help.
Confirmation Candels MTF labels of the channel color.
Thank @cos251 for this RSM_MTF_Labels code used to make this and @Christopher84 for this indicator.
Code:#Confirmation Candles MTF Channel Label. #Thank @cos251 for this RSM_MTF_Labels code used to make this. input period = AggregationPeriod.DAY; DefineGlobalColor("UpTrend", Color.Green); DefineGlobalColor("DownTrend", Color.RED); DefineGlobalColor("NoTrend", Color.GRAY); script CC_ { input aP = AggregationPeriod.DAY; #Keltner Channel def displace = 0; def factorK = 2.0; def lengthK = 20; def price = close(period = ap); input averageType = AverageType.SIMPLE; def trueRangeAverageType = AverageType.SIMPLE; def BulgeLengthK = 150; def SqueezeLengthK = 150; def BulgeLengthK2 = 40; def SqueezeLengthK2 = 40; def BulgeLengthPrice = 75; def SqueezeLengthPrice = 75; def BulgeLengthPrice2 = 20; def SqueezeLengthPrice2 = 20; def shift = factorK * MovingAverage(trueRangeAverageType, TrueRange(high(period = ap), close(period = ap), low(period = ap)), lengthK); def averageK = MovingAverage(averageType, price, lengthK); def AvgK = averageK[-displace]; def Upper_BandK = averageK[-displace] + shift[-displace]; def Lower_BandK = averageK[-displace] - shift[-displace]; def conditionK1 = price >= Upper_BandK; def conditionK2 = (Upper_BandK[1] < Upper_BandK) and (Lower_BandK[1] < Lower_BandK); def conditionK2L = (Upper_BandK[2] < Upper_BandK[1]) and (Lower_BandK[2] < Lower_BandK[1]); def conditionK3L = (Upper_BandK[3] < Upper_BandK[2]) and (Lower_BandK[3] < Lower_BandK[2]); def conditionK3 = (Upper_BandK[1] > Upper_BandK) and (Lower_BandK[1] > Lower_BandK); def BandwidthK = (Upper_BandK - Lower_BandK) / AvgK * 100; def condition_BWKUP = BandwidthK[1] < BandwidthK; def condition_BWKDOWN = BandwidthK[1] > BandwidthK; def BulgeK = Highest(BandwidthK, BulgeLengthK); def SqueezeK = Lowest(BandwidthK, SqueezeLengthK); def BulgeK2 = Highest(BandwidthK, BulgeLengthK2); def SqueezeK2 = Lowest(BandwidthK, SqueezeLengthK2); ################################################################# ########## Trend & Labels ######### ################################################################# def UpTrend_ = (Upper_BandK[1] < Upper_BandK) and (Lower_BandK[1] < Lower_BandK); def DownTrend_ = (Upper_BandK[1] > Upper_BandK) and (Lower_BandK[1] > Lower_BandK); plot Trend_ = if UpTrend_ then 1 else if DownTrend_ then 0 else -1; } def currentPeriod = GetAggregationPeriod(); def CC; if period >= currentPeriod { CC = CC_(aP = period); } else { CC = Double.NaN; } AddLabel(!IsNaN(CC), if period == AggregationPeriod.MONTH then "M" else if period == AggregationPeriod.WEEK then "W" else if period == AggregationPeriod.FOUR_DAYS then "4D" else if period == AggregationPeriod.THREE_DAYS then "3D" else if period == AggregationPeriod.TWO_DAYS then "2D" else if period == AggregationPeriod.DAY then "D" else if period == AggregationPeriod.FOUR_HOURS then "4H" else if period == AggregationPeriod.TWO_HOURS then "2H" else if period == AggregationPeriod.HOUR then "60m" else if period == AggregationPeriod.THIRTY_MIN then "30m" else if period == AggregationPeriod.TWENTY_MIN then "20m" else if period == AggregationPeriod.FIFTEEN_MIN then "15m" else if period == AggregationPeriod.TEN_MIN then "10m" else if period == AggregationPeriod.FIVE_MIN then "5m" else if period == AggregationPeriod.FOUR_MIN then "4m" else if period == AggregationPeriod.THREE_MIN then "3m" else if period == AggregationPeriod.TWO_MIN then "2m" else if period == AggregationPeriod.MIN then "1m" else "", if CC == 1 then GlobalColor("UpTrend") else if CC == 0 then GlobalColor("DownTrend") else GlobalColor("NoTrend"));
Thanks so much, @Christopher84 for generously sharing your wonderful work. Do you have a preference to use one over the other? If one is using CCC then CC is not needed, right?Hi Everyone!
I have just posted the most recent version of the (Consensus Confirmation Candles) C3 v5 on pg.1 of this thread. Notable changes include new method of determining price squeeze and reduction in the number of labels. The text in the labels is more descriptive and hopefully more easily understood. And for anyone who missed the last live discussion, I have scheduled another session this Friday @ 3:00 cst (same place, same time as the previous discussion). I am looking forward to a great discussion! Enjoy!
I personally prefer C3. It has evolved a bit further than its counterpart. However, the adjustable level on the Confirmation Candles can still be useful.Thanks so much, @Christopher84 for generously sharing your wonderful work. Do you have a preference to use one over the other? If one is using CCC then CC is not needed, right?
Hi diamondhands,Hey @Trader Raider Thank you so much for the kind reply and much appreciated. I have recently started using the Breakout Balanced along with V10 of confirmation candle ( my chart shows confirmation level and not consensus level which i presume are same thing ). However, the signals generated from Balance breakout are far more delayed with delayed exits. I have seen you participating in both the group ( that group is closed now for replies so i would want to ask you are you still actively using it and how do you coordinate entries and exits using both ?
Join useThinkScript to post your question to a community of 21,000+ developers and traders.
Start a new thread and receive assistance from our community.
useThinkScript is the #1 community of stock market investors using indicators and other tools to power their trading strategies. Traders of all skill levels use our forums to learn about scripting and indicators, help each other, and discover new ways to gain an edge in the markets.
We get it. Our forum can be intimidating, if not overwhelming. With thousands of topics, tens of thousands of posts, our community has created an incredibly deep knowledge base for stock traders. No one can ever exhaust every resource provided on our site.
If you are new, or just looking for guidance, here are some helpful links to get you started.