DIMA AVERAGES

DIMA AVERAGES

Type : Function, Name : Dima_MOMA

inputs:
Price(numericseries),
Length(numericsimple);

Value2 = 0;
for Value1 = 0 to Length — 1
begin
Value2 = Value2 + AbsValue(Price[Value1] — Price[Value1 + 1]);
end;

Value3 = 0;
if Value2 <> 0 then
begin
for Value1 = 0 to Length — 1
begin
Value3 = Value3 + Price[Value1] * (AbsValue(Price[Value1] — Price[Value1 + 1]) / Value2);
end;
end;

Dima_MOMA = Value3;

 

Type : Function, Name : Dima_VOMA

inputs:
Price(numericseries),
Length(numericsimple);

variables:
vol_sum(0);

vol_sum = 0;
for Value1 = 0 to Length — 1
begin
vol_sum = vol_sum + Volume[Value1];
end;

Value2 = 0;
if vol_sum <> 0 then
begin
for Value1 = 0 to Length — 1
begin
Value2 = Value2 + Price[Value1]*(volume[Value1] / vol_sum);
end;
end;

Dima_VOMA = Value2;
Type : Function, Name : Dima_WEVOMO

inputs:
Price(numericseries),
Length(numericsimple);

Value1 = (Dima_MOMA(Price, Length) + Dima_VOMA(Price, Length) + WAverage(Price, Length)) / 3;
Dima_WEVOMO = Value1;

 

 

Type : Indicator, Name : Dimainput:

Price(Close), Length(14);

Value1 = (Dima_MOMA(Price, Length) + Dima_VOMA(Price, Length)) / 2;
plot1(Value1, «VOMOMA»);
plot2(Dima_MOMA(Price, Length), «MOMA»);

plot3(Dima_WEVOMO(Price, Length), «WEVOMO»);

Николай Солабуто
Оцените автора
Николай Солабуто
Добавить комментарий