Can one of you coders create an ELD. Special thanks to Barry taylor for providing this.
Better Volume Indicator
Inputs: LowVol(True), ClimaxUp(True), ClimaxDown(True), Churn(True), ClimaxChurn(True), Color(Cyan), LowVolColor(Yellow), ClimaxUpColor(Red), ClimaxDownColor(White), ChurnColor(Green), ClimaxChurnColor(Magenta) , AvgColor(Red);
Variables: BarColor(Cyan), Lookback(20);
BarColor = Color;
If BarType > 1 then begin
Value1 = V;
Value2 = V*Range;
If Range <> 0 then Value3 = V/Range;
Condition1 = Value1 = Lowest(Value1,Lookback);
Condition2 = Value2 = Highest(Value2,Lookback);
Condition3 = Value3 = Lowest(Value3,Lookback);
Condition4 = Value3 = Highest(Value3,Lookback);
If LowVol and Condition1 then BarColor = LowVolColor;
If ClimaxUp and Condition2 and C > O then BarColor = ClimaxUpColor;
If ClimaxDown and (Condition2 or Condition3) and C < O then BarColor = ClimaxDownColor;
If Churn and Condition4 then BarColor = ChurnColor;
If ClimaxChurn and Condition4 and ((Condition2 and C > O) or ((Condition2 or Condition3) and C < O)) then BarColor = ClimaxChurnColor;
End;
If BarType <= 1 then begin
Value1 = UpTicks+DownTicks;
Value2 = UpTicks*Range;
Value3 = (UpTicks-DownTicks)*Range;
Value4 = DownTicks*Range;
Value5 = (DownTicks-UpTicks)*Range;
If Range <> 0 then begin
Value6 = UpTicks/Range;
Value7 = (UpTicks-DownTicks)/Range;
Value8 = DownTicks/Range;
Value9 = (DownTicks-UpTicks)/Range;
Value10 = (UpTicks+DownTicks)/Range;
End;
Condition1 = Value1 = Lowest(Value1,Lookback);
Condition2 = Value2 = Highest(Value2,Lookback);
Condition3 = Value3 = Highest(Value3,Lookback);
Condition4 = Value4 = Highest(Value4,Lookback);
Condition5 = Value5 = Highest(Value5,Lookback);
Condition6 = Value6 = Lowest(Value6,Lookback);
Condition7 = Value7 = Lowest(Value7,Lookback);
Condition8 = Value8 = Lowest(Value8,Lookback);
Condition9 = Value9 = Lowest(Value9,Lookback);
Condition10 = Value10 = Highest(Value10,Lookback) ;
If LowVol and Condition1 then BarColor = LowVolColor;
If ClimaxUp and (Condition2 or Condition3 or Condition8 or Condition9) and C > O then BarColor = ClimaxUpColor;
If ClimaxDown and (Condition4 or Condition5 or Condition6 or Condition7) and C < O then BarColor = ClimaxDownColor;
If Churn and Condition10 then BarColor = ChurnColor;
If ClimaxChurn and Condition10 and (((Condition2 or Condition3 or Condition8 or Condition9) and C > O) or ((Condition4 or Condition5 or Condition6 or Condition7) and C < O)) then BarColor = ClimaxChurnColor;
End;
Plot1(Value1,"Volume",Bar Color);
Plot2(Average(Value1,100) ,"Avg",AvgColor);
{************************ ** Change Log: ************************* *}
{23 November 2007 - Added LowChurn colored volume bars }
{19 April 2008 - Got rid of LowChurn and replaced with ClimaxDown }
{19 April 2008 - Added open & close conditions with ClimaxUp and ClimaxDown }
{19 April 2008 - Added different calculations for tick/intra-day charts }
Better Volume PaintBar
Inputs: LowVol(True), ClimaxUp(True), ClimaxDown(True), Churn(True), ClimaxChurn(True), LowVolColor(Yellow), ClimaxUpColor(Red), ClimaxDownColor(White), ChurnColor(Blue), ClimaxChurnColor(Magenta) , Lookback(20);
Variables: BarColor(Green);
BarColor = Green;
If BarType > 1 then begin
Value1 = V;
Value2 = V*Range;
If Range <> 0 then Value3 = V/Range;
Condition1 = Value1 = Lowest(Value1,Lookback);
Condition2 = Value2 = Highest(Value2,Lookback);
Condition3 = Value3 = Lowest(Value3,Lookback);
Condition4 = Value3 = Highest(Value3,Lookback);
If LowVol and Condition1 then BarColor = LowVolColor;
If ClimaxUp and Condition2 and C > O then BarColor = ClimaxUpColor;
If ClimaxDown and (Condition2 or Condition3) and C < O then BarColor = ClimaxDownColor;
If Churn and Condition4 then BarColor = ChurnColor;
If ClimaxChurn and Condition4 and ((Condition2 and C > O) or ((Condition2 or Condition3) and C < O)) then BarColor = ClimaxChurnColor;
End;
If BarType <= 1 then begin
Value1 = UpTicks+DownTicks;
Value2 = UpTicks*Range;
Value3 = (UpTicks-DownTicks)*Range;
Value4 = DownTicks*Range;
Value5 = (DownTicks-UpTicks)*Range;
If Range <> 0 then begin
Value6 = UpTicks/Range;
Value7 = (UpTicks-DownTicks)/Range;
Value8 = DownTicks/Range;
Value9 = (DownTicks-UpTicks)/Range;
Value10 = (UpTicks+DownTicks)/Range;
End;
Condition1 = Value1 = Lowest(Value1,Lookback);
Condition2 = Value2 = Highest(Value2,Lookback);
Condition3 = Value3 = Highest(Value3,Lookback);
Condition4 = Value4 = Highest(Value4,Lookback);
Condition5 = Value5 = Highest(Value5,Lookback);
Condition6 = Value6 = Lowest(Value6,Lookback);
Condition7 = Value7 = Lowest(Value7,Lookback);
Condition8 = Value8 = Lowest(Value8,Lookback);
Condition9 = Value9 = Lowest(Value9,Lookback);
Condition10 = Value10 = Highest(Value10,Lookback) ;
If LowVol and Condition1 then BarColor = LowVolColor;
If ClimaxUp and (Condition2 or Condition3 or Condition8 or Condition9) and C > O then BarColor = ClimaxUpColor;
If ClimaxDown and (Condition4 or Condition5 or Condition6 or Condition7) and C < O then BarColor = ClimaxDownColor;
If Churn and Condition10 then BarColor = ChurnColor;
If ClimaxChurn and Condition10 and (((Condition2 or Condition3 or Condition8 or Condition9) and C > O) or ((Condition4 or Condition5 or Condition6 or Condition7) and C < O)) then BarColor = ClimaxChurnColor;
End;
If BarColor <> Green then PlotPaintBar(H,L,O,C,"Bet terVol",BarColor);