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

[amibroker] Re: Why not



PureBytes Links

Trading Reference Links

BarCount is a single value that indicates the total number of bars
available for the current stock. It will likely change from stock to
stock.

If you change nNumBarsToScan to BarCount-1, then assuming curBar is
valid bar index, the loop will only run once when curBar = BarCount-1.

I don't know what the rest of the code is doing, but that would make
curBar a fairly redundant variable.

Regards,
GP


--- In amibroker@xxxxxxxxxxxxxxx, "mytakeismine" <mytakeismine@xxx> wrote:
>
> Hi, need a little help or an explanation.
> While using one of the Zig Zag afl's (GordonWrose)in the AA explorer I 
> wasn't getting what I wanted when I realized that I was only looking 
> at 120 days? 
> 
> nNumBarsToScan = 120;
> if (curBar >= nNumBarsToScan ) {
> 	for (i=0; i<nNumBarsToScan; i++) {
> 
> So I switched the 120 with " barcount - 1 "  Wouldn't that be a fixed 
> number and not an array?
>




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/