YungTraderFromMontana
Well-known member
I'm trying to overlay accumulation distribution on my chart but the color are too bright and distracting. Could anyone make it so the colors are more see through and don't clash with the candles. I know their is a feature on volume profile to do this but I can't replicate it on other indicators.
Here's the accumulation distribution code:
Here is the opacity control feature in volume profile:
I would like the end goal to be an opacity control of the rangeratio.
Here's the accumulation distribution code:
Code:
declare lower;
input length = 6;
input factor = 0.95;
input mode = {default Range, ATR};
def range;
switch (mode) {
case Range:
range = Highest(high, length) - Lowest(low, length);
case ATR:
range = reference ATR();
}
plot RangeRatio = (range / range[length])/2;
plot RangeFactor = factor/2;
RangeRatio.SetPaintingStrategy(PaintingStrategy.HISTOGRAM);
RangeRatio.DefineColor("Consolidation", GetColor(4));
RangeRatio.DefineColor("Non-consolidation", GetColor(1));
RangeRatio.AssignValueColor( if (RangeRatio < RangeFactor) then RangeRatio.Color("Consolidation") else RangeRatio.Color("Non-consolidation"));
RangeFactor.SetDefaultColor(GetColor(7));
RangeRatio.SetPaintingStrategy(PaintingStrategy.HISTOGRAM);
RangeRatio.DefineColor("Consolidation", GetColor(4));
RangeRatio.DefineColor("Non-consolidation", GetColor(1));
RangeRatio.AssignValueColor( if (RangeRatio < RangeFactor) then RangeRatio.Color("Consolidation") else RangeRatio.Color("Non-consolidation"));
RangeFactor.SetDefaultColor(GetColor(7));
Here is the opacity control feature in volume profile:
Code:
input showPointOfControl = yes;
input showValueArea = yes;
input valueAreaPercent = 70;
input opacity = 50;
DefineGlobalColor("Profile", GetColor(1));
DefineGlobalColor("Point Of Control", GetColor(5));
DefineGlobalColor("Value Area", GetColor(8));
vol.show(globalColor("Profile"), if showPointOfControl then globalColor("Point Of Control") else color.current, if showValueArea then globalColor("Value Area") else color.current, opacity);
I would like the end goal to be an opacity control of the rangeratio.