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

Re: [amibroker] Re: Secure AFL?



PureBytes Links

Trading Reference Links

Thanks Ara,

I was probably looking for others who suffer from the same issue with a 
view of fixing/padding the database data given the zeros also affect the 
graphing as well.

Many thanks for the code snippet which I'll endevour to incorporate in a 
backtest (I'm still a newbie at all this :) )

Cheers
Martin


> Martin
> 
> if you check for volume and it is zero, then fing the prior nonzero volume
> day and use thr prices for that day
> 
> if (volume[barindex()]==0)
> //find first bar with non-zero volume
> Bar_Num=BarsSince(Volume!=0);
> C=Ref(C,-Bar_Num);
> 
> 
> I did not test this code ... but you get the idea
> 
> 
> ----- Original Message -----
> From: "Martin Cooney" <martin@xxxxxxxxxxxxx>
> To: <amibroker@xxxxxxxxxxxxxxx>
> Sent: Monday, July 26, 2004 6:14 PM
> Subject: [amibroker] data issues with zero volume days
> 
> 
>  > Hi All,
>  >
>  > The data I currently obtain from my data provider essentially lists
>  > prices for zero volume days as zero i,e High=0, Low=0, Close=0, Open=0.
>  >
>  > Unfortunately, when backtesting these values cause the system to cop a
>  > 100% loss etc which, you can well imagine, is not what I'd like to see
>  > happen. It also causes down spikes in graphing.
>  >
>  > Ideally, I'd like to 'fix' the zero value days with value of the
>  > previous day's Close.
>  >
>  > Does anyone else have/had this problem and some suggestions on an
>  > appropriate remedy ?
>  >
>  > Best Regards
>  > Martin



------------------------ Yahoo! Groups Sponsor --------------------~--> 
Yahoo! Domains - Claim yours for only $14.70
http://us.click.yahoo.com/Z1wmxD/DREIAA/yQLSAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

Check AmiBroker web page at:
http://www.amibroker.com/

Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.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/