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

Re: [amibroker] (unknown)



PureBytes Links

Trading Reference Links

Hi Geoff and All,

I am glad that you are willing to help other users and I have no objections if
you write an article about AFL. I would be more than happy to include it in the newsletter
(if you agree). I have got only one kind request - could you please send me
the article first for a review just to fix possible errors/misconceptions (if any)?

Now just a few words about AFL & other programming languages:

The AFL is not a general-purpose language, it is designed to make writing trading
formulas easier. And yes, it is array based, and this greatly simplyfies writing
the formulas. Just imagine how much code you will need to write to check for simple
crossover in C:

cross( int Size, float *Array1, float *Array2, float *Result )
{
for( int i = 1; i < Size; i++ )
{
if( Array1[ i - 1 ] < Array2[ i - 1 ] &&
Array1[ i ] >= Arrays[ i ] )
{
Result[ i ] = 1;
}
else
{
Result[ i ] = 0;
}
}
}

In AFL you just write:

cross( Array1, Array2 );

Best regards,
Tomasz Janeczko


----- Original Message -----
From: "u7351a@xxxx" <gmulhall@xxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Wednesday, April 04, 2001 00:57
Subject: [amibroker] (unknown)


Hi Tomasz and all,

I'm an ex programmer and as such was initially expecting that AFL (AmiBroker Formula Language) was like other languages such as
BASIC or C etc etc.

It quickly became apparent that this was not the case because you cannot write loops etc.

So then I just used the most basic functionality to plot indicators.

I an Ah Hah experience this weekend where I realised that AFL simply creates arrays of values and is then able to compare these
arrays and create new arrays.

So now I'm comfortable I can program AFL to do pretty much what I want. I released the genie for myself which is fantastic.

Thus it would be good to have in the manual a pictorial diagram of an array of say closing prices and an array of say a moving
average below it. Then a discussion of how AFL compares the two arrays to generate the buy or sell array for from the first two
arrays.

A would expect some users may even be wondering what an array is so a picture
should assist.

Excell is probably a good tool to do this in so I'll knock something up on the weekend IF ANYONE IS INTERESTED and Tomasz has no
objections.

Regards,

Geoff

--------------------------------------------------------------------
Mail2Web - Check your email from the web at
http://www.mail2web.com/ .





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