Buy Order:
pds:=22;
pds1:=35;
mf:=C-(H+L)/2+Typical()-Ref(Typical(),-1);
fve:=Sum(If(mf>0.3*C/100,+V, If(mf<-0.3*C/100, -V,0)),pds)/Mov(V,pds,S)/pds*100;
((If(LinRegSlope(fve,pds1)>0,1,-1)-
If(LinRegSlope(C,pds1)>0,1,-1))>0) and
cross(fve,-5)
Sell Order:
pds:=22;
pds1:=25;
mf:=C-(H+L)/2+Typical()-Ref(Typical(),-1);
fve:=Sum(If(mf>0.3*C/100,+V, If(mf<-0.3*C/100, -V,0)),pds)/Mov(V,pds,S)/pds*100;