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

[amibroker] Function for Dips and Tops



PureBytes Links

Trading Reference Links

Everything that I do requires me to create what I call dip and top codes.  I looked in the alphabetical list of AFL functions, but saw nothing that would do what I want.  I an NOT looking to identify what I think are called pivots, where the price changes from an uptrend to a downtrend or vice versa.  The below dip and top codes do exactly what I want.
I would like to simply be able to use something like this directly below instead of having to constantly create my own dip and top codes each time I create a new custom indicator.
 
Dip(AllKLTavr); and Top(AllKLTavr); 
 
Are there any AFL functions that do this?  Remember, the ones that use Zig won't work the way the code below works.  I would appreiciate hearing about any AFL functions that do this? Ron D
 

butn=AllKLTavr;

butntop=butn<Ref(butn,-1) AND Ref(butn,-1)>Ref(butn,-2);

butndip=butn>Ref(butn,-1) AND Ref(butn,-1)<Ref(butn,-2);

 

 


Check AmiBroker web page at:
http://www.amibroker.com/

Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html



Yahoo! Groups Sponsor
ADVERTISEMENT


Yahoo! Groups Links

No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.300 / Virus Database: 265.8.7 - Release Date: 2/10/2005