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

[amibroker] Safezone Stop



PureBytes Links

Trading Reference Links

Hi All,
 
Consider the following for the safezone stop:

B=Low;

B1=Ref(L,-1);

Y=IIf(B<B1,B1-B,0);

Y1=Sum(Y,22);

Y2=IIf(B<B1,1,0);

Y3=Sum(Y2,22);

Y4=Y1/Y3;

Y5=B1-(2*Y4);

Y6=Ref(Y5,-1);

Y7=Max(Y5,Y6); 

Graph2=Y7;

Graph2Style=1+4;

Graph2Color=9;

Is there anyway to refine the formula to prevent it from lowering 
stops in an uptrend? I.e If the formula tells us to lower the stop, 
it simply leaves it at the previous day's level.

Thanks for the help
Russ




------------------------ Yahoo! Groups Sponsor ---------------------~-->
DVD Rentals with No Late Fees - Try Netflix for FREE!
http://us.click.yahoo.com/ZKLNcC/pEZFAA/i5gGAA/GHeqlB/TM
---------------------------------------------------------------------~->

Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 

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