InvestorsHub Logo
Followers 11
Posts 2529
Boards Moderated 1
Alias Born 04/03/2009

Re: None

Sunday, 09/29/2013 7:11:51 PM

Sunday, September 29, 2013 7:11:51 PM

Post# of 3631
Got rid of the Better Momentum Volume. I was unable to get good signals with it so, went back to my volume code and modified it. I added a cloud so you can run two averages at the same time and see the crossover better. Signal is when averages cross. Sometimes volume moves up on lower average and sometimes on higher average or vice versa so, you can't assume for example shorter term average crossover means up. It means shorter term volume is building and the trend is going to change one way or the other. You have to know the direction of the trend. I am using 25 right now for lower average but, this can be tweaked if necessary. I use the crossover of the averages as a confirming signal.

#Volume with 2 Averages
#

declare lower;
declare zerobase;

input length = 50;
input length2 = 25;
input High_Volume = 1;

plot Vol = volume;
plot VolAvg = Average(volume, length);
plot VolAvg2 = Average(volume, length2);
plot HighVolume = High_Volume;

Vol.SetPaintingStrategy(PaintingStrategy.HISTOGRAM);
Vol.SetLineWeight(3);
Vol.DefineColor("Up", Color.UPTICK);
Vol.DefineColor("Down", Color.DOWNTICK);
Vol.AssignValueColor(if close > close[1] then Vol.color("Up") else if close < close[1] then Vol.color("Down") else GetColor(1));
VolAvg.SetDefaultColor(GetColor(8));
VolAvg.SetDefaultColor(GetColor(0));
HighVolume.SetDefaultColor(GetColor(5));

Vol.HideTitle();
VolAvg.HideTitle();
VolAvg2.HideTitle();
HighVolume.HideTitle();

plot upper = VolAvg;
upper.SetDefaultColor(Color.WHITE);
plot lower = VolAvg2;
lower.SetDefaultColor(Color.BLUE);
AddCloud(upper, lower, color.LIGHT_RED, color.BLUE);


Join the InvestorsHub Community

Register for free to join our community of investors and share your ideas. You will also get access to streaming quotes, interactive charts, trades, portfolio, live options flow and more tools.