Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 12/14/2009(UTC) Posts: 140 Location: Austria
|
Here are the formulas and signals - but I can not see how this should work in a performant way.. { Milk Money Trade - signals - interpretation vienna } AO:=Mov((H+L)/2,5,S)-Mov((H+L)/2,21,S);
green:=Mov(C,20,E); v1:=Mov(C,20,E)+((4/100)*Mov(C,20,E)); v2:=Mov(C,20,E)-((4/100)*Mov(C,20,E)); atr14:=ATR(14); signal1:=If((C>v1) AND (LinRegSlope(ao,2)>0)<>(LinRegSlope(Ref(ao,-1),2)>0),1,0); signal2:=If((C<v2) AND (LinRegSlope(ao,2)>0)<>(LinRegSlope(Ref(ao,-1),2)>0),1,0); signalstop:=If(Cross(C,green) OR Cross(green,C),1,0);
v1;green;v2;
signal1 * LastValue(C); signal2 * LastValue(C); signalstop * LastValue(C);
as I understood: signal1 and signal2 should be the signal for enter long/short - signalstop is the signal to stop this positions.. (maybe there is some error in the formula - or the system is not working as expected)
|