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

Re: [amibroker] SetBarsRequired()...?



PureBytes Links

Trading Reference Links

Hi - Probably best to start at the beginning. TJ invented QuickAFL to reduce 
the time it takes charting code to execute. It is turned on by default in 
charting ( AA does not currently use it ). It works by creating smaller 
arrays from your full arrays and operating on them instead. The smaller 
arrays consist of the bars you can see plus some number of bars immediately 
preceding them which are used to "initialize" the arrays so correct values 
are achieved by the time they reach the first visible bar. But certain 
applications/formulas need to use more bars so TJ provided SetBarsRequired() 
so you can specify more bars if you need to. As a practical matter, I think 
most people use it to just "shut off" QuickAFL by using numbers larger than 
the size of their entire array, then AB will just use all bars. So yes it 
will slow down code execution as it defeats the purpose that QuickAFL was 
invented for.

Re crosses changing bars, I don't think that should happen, I would guess it 
probably means you are not using enough bars. Tough to know what is 
happening without your code, and not sure I would know what is happening 
behind the scene even if I did have it. You could try playing around with 
different values to see what happens...

Steve

----- Original Message ----- 
From: "sidhartha70" <sidhartha70@xxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Wednesday, June 04, 2008 2:10 PM
Subject: [amibroker] SetBarsRequired()...?


> Hi All,
>
> I'm a little confused about the use of SetBarsRquired()... How do I
> know specifically when I need to use it...? And How do I know how many
> bars to specify IF I do need to use it...??
>
> Also, doesn't it really very significantly slow code execution
> down...? From my experimentation, it seems to.
>
> I currently have some indicators plotting (e.g. fast and slow lines
> crossing) and the exact bar on which a cross occurs seems to move as I
> scroll backwards and forwards along a chart....
>
> Any ideas...?
>
>
> ------------------------------------
>
> 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 NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
> http://www.amibroker.com/devlog/
>
> For other support material please check also:
> http://www.amibroker.com/support.html
> Yahoo! Groups Links
>
>
>
> 



------------------------------------

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 NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

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/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/amibroker/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:amibroker-digest@xxxxxxxxxxxxxxx 
    mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx

<*> 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/