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

[EquisMetaStock Group] Please check my formula



PureBytes Links

Trading Reference Links


What I'm trying to do is compare patterns, when two securities are 
doing the same or opposite things to each other - so that if they are 
both moving in the same direction I get a signal, or if they are 
moving converse I get a signal, and then I want it to display 
whatever the last signal was till it changes again - I think what 
I've done should be correct, but everytime I finish editing the 
indicator builder and close it, I just get a blank section with no 
lines or anything, or metastock crashes (running MetaStock Pro 7.2) - 
I know it doesn't specially like using the PREV function, but I 
thought it should be able to handle it - unless I've done something 
wrong.  Any ideas what my problem might be - my formula, or my 
hardware??
Thanks for your help

bob:=Security("C:\MetaStock\Data\cbavp", C);
bill:=Security("C:\MetaStock\Data\cbavc",C);

bob3:=Mov(bob,3,S);
bill3:=Mov(bill,3,S);

sim:=((bill3<Ref(bill3,-1) AND Ref(bill3,-1)<Ref(bill3,-2) AND Ref
(bill3,-2)<Ref(bill3,-3)) AND (bob3<Ref(bob3,-1) AND Ref(bob3,-1)<Ref
(bob3,-2) AND Ref(bob3,-2)<Ref(bob3,-3))) 
OR 
((bill3>Ref(bill3,-1) AND Ref(bill3,-1)>Ref(bill3,-2) AND Ref(bill3,-
2)>Ref(bill3,-3)) AND (bob3>Ref(bob3,-1) AND Ref(bob3,-1)>Ref(bob3,-
2) AND Ref(bob3,-2)>Ref(bob3,-3)));

mirr:=((bill3<Ref(bill3,-1) AND Ref(bill3,-1)<Ref(bill3,-2) AND Ref
(bill3,-2)<Ref(bill3,-3)) AND (bob3>Ref(bob3,-1) AND Ref(bob3,-1)>Ref
(bob3,-2) AND Ref(bob3,-2)>Ref(bob3,-3)))
OR 
((bill3>Ref(bill3,-1) AND Ref(bill3,-1)>Ref(bill3,-2) AND Ref(bill3,-
2)>Ref(bill3,-3)) AND (bob3<Ref(bob3,-1) AND Ref(bob3,-1)<Ref(bob3,-
2) AND Ref(bob3,-2)<Ref(bob3,-3)));

If(mirr<>1 AND sim<>1,PREV,If(mirr=1,1,2))






------------------------ Yahoo! Groups Sponsor --------------------~--> 
Has someone you know been affected by illness or disease?
Network for Good is THE place to support health awareness efforts!
http://us.click.yahoo.com/Rcy2bD/UOnJAA/cosFAA/BefplB/TM
--------------------------------------------------------------------~-> 

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/equismetastock/

<*> To unsubscribe from this group, send an email to:
    equismetastock-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/