[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[EquisMetaStock Group] Reverse Val



PureBytes Links

Trading Reference Links

hi Preston
how to make reverse style of this code below ,
its given a signal acc value when the price rising and if the price going down its just give "0" signal
i would like to change to be when the price going up the signal "0" and when the price going down its given the dist value as show an indicator. it just reverse of what is code run as usual.
 
start:=TroughBars(1,C,5)=0;
end:=PeakBars(1,C,5)=0;
init:=Cum(IsDefined(start+end))=1;
flag:=ValueWhen(1,start-end<>0 OR init,start);
start:=flag*(Alert(flag=0,2) OR start*Cum(start)=1);
end:=(flag=0)*(Alert(flag,2) OR end*Cum(end)=1);
value:=V;
acc:=Cum(flag*value);
accVal:=acc-ValueWhen(1,end,acc);
accVal;
start-end;
 
Rgds
SATH

__._,_.___

Your email settings: Individual Email|Traditional
Change settings via the Web (Yahoo! ID required)
Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe

__,_._,___