PureBytes Links
Trading Reference Links
|
James,
I will read and reread your post and hopefully it will sink
in. Had a power failure otherwise I would of responded sooner.
Thanks,
john
--- In amibroker@xxxxxxxxxxxxxxx, james brady <jimbrady51@xxxx> wrote:
> I'm just a newbie, and I'm not a programmer, so
> forgive me if I mislead you, but here's my answer.
> You have to get used to the idea of a 'function.' In
> mathematics, y=sin(x) is a function. If you give a
> value of x, the function gives you back, or returns
> the value sin(x). Its difficult to use the expression
> 'sin' because the immediate question is "sin of what?"
>
>
> In AFL, if you give a function something, the
> function will give something back to you. To put it
> another way: a function is defined to be a thingamabob
> that, if you give it something, it gives you back
> something else. What you give the function is called
> the 'arguments,' and the arguments are presented in
> the parentheses. For example, "var1 = MA(C,10)" means
> "I am creating a variable called var1, and it is equal
> to the 10-day moving average of the close." Note
> that C, i.e. "Close," and the number 10 are being
> 'plugged in' to the concept 'moving average.' I can't
> ask for the numbert MA without specifying, for
> example, close and 10, so these two things are
> considered my 'arguments.'
>
> Now, sometimes the arguments are understood. For
> example, with the MACD, the arguments are fast and
> slow, usually two different numbers of days, but if
> you write MACD(), the program assumes you mean, I
> believe it is, 12 and 26. You still have to write the
> parentheses, however, because otherwise the program
> thinks you have just made up some variable of your
> own, tried to name it "MACD" and it is waiting for you
> to assign some number to it (actually the program
> would probably not let you do that anyway because MACD
> is a set of letters that is already reserved.)
>
> I think that DateTime() is an example where the
> argument is only going to be expressed as an
> 'understood' variable: it is the date and time at
> which the hypthetical buy or sell occurred. But the
> program wants me to put the parentheses, perhaps just
> to remind me that "DateTime" is the function that
> takes a moment in the past and gives you back, or
> returns, the actual date and time, e.g. 1:35 PM May
> 11, 2005.
>
> Jim B
> --- John <jea55129@xxxx> wrote:
> > Group,
> > Can someone please describe in laymans terms what
> > "()" means.
> >
> > func() /* function call no arguments */
> >
> > Thanks,
> >
> > John
> >
> >
> >
> >
> >
> >
>
>
>
> Discover Yahoo!
> Get on-the-go sports scores, stock quotes, news and more. Check it
out!
> http://discover.yahoo.com/mobile.html
------------------------ 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/GHeqlB/TM
--------------------------------------------------------------------~->
Please note that this group is for discussion between users only.
To get support from AmiBroker please send an e-mail directly to
SUPPORT {at} amibroker.com
For other support material please check also:
http://www.amibroker.com/support.html
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/amibroker/
<*> To unsubscribe from this group, send an email to:
amibroker-unsubscribe@xxxxxxxxxxxxxxx
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
|