//ACVO Indicator:
Inputs:
xmaf(10),
xmam(20),
xmas(50);
Variables:
fv(0),
mv(0),
sv(0),
condition(0);
fv = xaverage(c,xmaf);
mv = xaverage(c,xmam);
sv = xaverage(c,xmas);
If fv > mv and mv > sv and fv > sv then condition = 1
Else
If fv < mv and mv < sv and fv < sv then condition = -1
Else condition = 0;
plot1(condition);
If condition <> condition[1] then alert;
//ACVO Strategy Script
Inputs:
xmaf(10),
xmam(20),
xmas(50);
Variables:
fv(0),
mv(0),
sv(0),
condition(0);
fv = xaverage(c,xmaf);
mv = xaverage(c,xmam);
sv = xaverage(c,xmas);
If fv > mv and mv > sv and fv > sv then condition = 1
Else
If fv < mv and mv < sv and fv < sv then condition = -1
Else condition = 0;
If condition = 1 then buy this bar close;
If condition = -1 then sellshort this bar close;
If condition = 0 then begin
Buytocover this bar close;
Sell this bar close;
end;