Stock Portfolio Organizer

The ultimate porfolio management solution.

Shares, Margin, CFD's, Futures and Forex
EOD and Realtime
Dividends and Trust Distributions
And Much More ....
For Portfolio Manager Click Here

WiseTrader Toolbox

#1 Selling Amibroker Plugin featuring:

Advanced Adaptive Indicators
Advanced Pattern Exploration
Neural Networks
And Much More ....
Find Out More Here

Volume Adjusted Moving Average for Amibroker (AFL)
kaiji
about 14 years ago
Amibroker (AFL)

Rating:
5 / 5 (Votes 1)
Tags:

Volume Adjusted Moving Average

By kysiek

Screenshots

Indicator / Formula

Copy & Paste Friendly
Period = Param("Period", 50, 1, 100);
agg = 0;
for (i = 0; i < BarCount; i++)
{
  Vama[i] = 0;
}

for (i = 1; i < BarCount; i++)
{
  agg = agg + Volume[i];
}

ave = agg / (BarCount - 1);


for (i = 1; i < BarCount; i++)
{
  weight_day[i] = int((Volume[i] / ave) - 0.5) + 1;
}

agg = 0;
for (i = 1; i < BarCount; i++)
{
  index = i;
  Copy_wd = weight_day;
  for (j = 0; j < Period; j++)
  {
    if (Copy_wd[index] == 0)
    {
      index--;
    };
    agg = agg + C[Index];
    Copy_wd[index]--;
  }
  Vama[i] = agg / Period;
  agg = 0;
}

Plot(Vama, "Vama", ParamColor("Vama", colorRed), 1);
Plot(C, "Price", ParamColor("Price", colorBlack), 1);
Plot(MA(C, Period), "Ma", colorBlue, 1);
Short = Cover = 0;
Buy = Cross(C, Vama);
Sell = Cross(Vama, C);

0 comments

Leave Comment

Please login here to leave a comment.

Back