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

Adaptivity in AFL



PureBytes Links

Trading Reference Links

Hi,

Got this from Metastockusers mailing list:

>The Highest High Value function will only accept numbers e.g.
>HHV(H,6). Now: how can I make this adaptive? For example I would like
>to code a channelbreakout and measure the length of the channel
>depending of the value of the ADX. It would be so simple to code like
>this:
>
>CL:=ADX(14);
>C>=HHV(H,100/CL)
>
>but that won´t be accepted. The only thing I can think of was
>constructing an endless if statement that assigned every single adx
>value in that manner:
>
>if adx(14)=30, HHV(H,100/30),
>if adx(14)=29, HHV(H,100/29),
>if adx(14)=28, HHV(H,100/28),
>and so on...Well I tried to this also and guess what... the whole
>system broke down *grr*

Well, what is impossible with $500 software is possible with AmiBroker:

CL = ADX(14);
buy = H >= HHV(H,100/CL);

If you take a look at the latest release notes you will find that more
and more functions in AFL support variable periods.

Best regards,
Tomasz Janeczko
===============
AmiBroker - the comprehensive share manager.
http://www.amibroker.com