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

RE: ZigZag validity



PureBytes Links

Trading Reference Links

hi,
what do you think about the following old indicator?

{ZigZag Symmetry}
V1:=Input("% Change",.1,50,2);
P1:=PeakBars(1,C,V1);
T1:=TroughBars(1,C,V1);
ValueWhen(1,P1=0,T1)/ValueWhen(1,T1=0,P1);1

don't remember where it come from.
gg


At 19.43 19/02/02 +0200, you wrote:
>First I want to thank you all for your great interest in my work.
>
>To Lionel Issen:
>Lionel thanks you for your praising comments.
>
>To Brian Sullivan and Marco"shineon":
>Brian and Marco thank you for your compliments and your suggestions about
>the article I am about to write.
>
>To Jayson, Steve and ART:
>Thank you for your comments and questions, which helped me and the rest of
>us to clarify things about my indicator.
>
>To Roy Larsen:
>Thanks again Roy for your great interest and contribution.
>
>Now back to ZigZag validity:
>
>Roy located a problem, which is more obvious when one uses small percent
>values (I tested with 3%) especially in choppy markets. The problem was that
>validity dropped to zero each time zigzag changed direction, regardless of
>what the %change was. Though both the Zigzag and the ZigZag validity
>indicators, in my opinion, do not have much to offer in such markets, this
>remark of Roy's was a very useful one because it gave me the chance to
>correct this weak point and at the same time to make the code simpler.
>
>So, here is the new version
>
>
>{ZigZag validity by Spyros Raftopoulos}
>
>perc:=Input("Percent",2,100,10);
>Z:=Zig(C,perc,%);
>last:=ValueWhen(1,
>( Z > Ref(Z,-1) AND Ref(Z,-1) < Ref(Z,-2) )
>OR
>( Z < Ref(Z,-1) AND Ref(Z,-1) > Ref(Z,-2) ),
>Ref(Z,-1));
>pc:=(C-last) * 100 / last;
>pc:= Abs(pc);
>SD:=(z>Ref(z,-1) AND Ref(z,-1)>Ref(z,-2)) OR (z<Ref(z,-1) AND
>Ref(z,-1)<Ref(z,-2));
>res:=If(pc>=perc ,1,0);
>If(Alert(res,2) AND SD,1,res);
>
>If any of you encounter any other problems please let me know.
>
>Happy trading