PureBytes Links
Trading Reference Links
|
Gerry,
The reason you are getting an error is because you are trying to do
a string function on an array.
Also, I do not believe you can use "Date" in the Foreign() statement. ie.
Re UserGuide:
DATAFIELD defines which array is referenced. Allowable data fields:
"open", "close", "high", "low", "volume", "interest".
Unless you have unadjusted close price in your database, Im not to sure
how you are going to go about adjusting the dividend price.
I can't follow your process to establish dividend adjustested prices, is
it possible to re-explain?
ATB
Michael.
gerryjoz wrote:
>Michael,
>i am trying to use your data to establish dividend adjusted prices. I
>have done this for 50 stocks for a couple of years or so in excel but
>it is tedious to update and get back into AB.
>I want to write out the cumulative dividend as an exploration, so i
>need to match the ex dividend date to the current bar date.
>when i try to compare the -DIVD data with the vanilla price data on
>DATE i get a type mismatch.
>my code snippet looks like so, having selected ANZ as a test case:
>/*part of dividend adjustment - determine cumulative dividend*/
>x=StrLeft(Name(),3);
>select=StrLeft(x,3)=="ANZ" AND StrLen(Name())==3;
>Filter= select;
>divfile=x+"-DIVD";
>fd=Foreign(divfile,"Date");
>dd=StrLeft(fd,2); //get type error here
>
> Any hint on how to perform the match betwoeen the two files?
>once i get a match i can write out the cumulative dividend, and then
>i can backwards adjust the OHLC to create a "-DA" file which would
>allow dividend insensitive backtesting.
>
>
>
------------------------ Yahoo! Groups Sponsor --------------------~-->
Try Online Currency Trading with GFT. Free 50K Demo. Trade
24 Hours. Commission-Free.
http://us.click.yahoo.com/DldnlA/9M2KAA/U1CZAA/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/
|