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

RE: [amibroker] storing fundamentals and other data for each stock



PureBytes Links

Trading Reference Links

thanks Tomasz, most helpful as usual.

thanks for getting me thinking about using the automation model within AFL.
I'd thought of it as a way to control AB from other applications, but I see
that there are things AB can do via OLE that AFL can't do directly.

and just for the record, I too agree that the enhanced backtester should be
a higher priority than custom stock fields, though they would be nice some
day.

dave

> If you are using Quotes Plus via plugin you can get most of fundamentals
> using GetExtraData function:
> http://www.amibroker.com/guide/afl/afl_view.php?name=GETEXTRADATA
>
>
> > - is there any way to fill AB's Financial Results data from
> QuotesPlus data?
> Not yet, but use GetExtraData instead.
>
> >
> > - is there any way to make use of AB's Financial Results data
> with AFL? can
> > it be used in indicators or backtests?
>
> Yes. All fundamentals are accessible via AMiBroker OLE interface,
> see properties of Stock object (Automation Object model section
> of the guide),
> as you can access OLE from scripting,
> you can access them from AFL.
>
> Example:
>
> EnableScript("jscript");
>
> ticker=Name();
>
> <%
>
> AB = AFL.CreateObject("Broker.Application");
>
> AFL("income1")=AB.Stocks(AFL("ticker")).FinanceIncome(0);
>
> AFL("income2")=AB.Stocks(AFL("ticker")).FinanceIncome(1);
>
> AFL("income3")=AB.Stocks(AFL("ticker")).FinanceIncome(2);
>
> AFL("income4")=AB.Stocks(AFL("ticker")).FinanceIncome(3);
>
> %>
>
> AddColumn(income1, "Income 1st quarter" );
>
> AddColumn(income2, "Income 2nd quarter" );
>
> AddColumn(income3, "Income 3rd quarter" );
>
> AddColumn(income4, "Income 4th quarter" );
>
> Filter=BarIndex()==BarCount-1;
>
>
> >
> > - is there any way to set AB's Financial Results data procedurally using
> > AFL?
>
>
> Yes, the same way as shown above (properties of Stock object are writable)
>
>
>
> >
> > - is there any other place within AB we can store custom data
> for a specific
> > stock? ideally it would be per day, but a way to do that per
> stock over all
> > bars would be better than nothing.
>
> You can re-use existing fields (including OpenInt that is not
> used for stocks),
> or you can use artifical ticker for that (say MSFT-DATA).
>
> It is also possible to write a data plugin that will allow that.
>
> >   I know we can store it in our own files outside AB, and I know we can
> > create pseudo-tickers to hold this kind of data. I'm wondering
> if it can be
> > done within AB itself. if not, I'd like to formally make a
> feature request
> > for user-defined fields that hold data per stock per bar.
>
> One day this will be added but right now I am working on
> backtester enhancements.
>
>
> Hope this helps.
>
>
> Best regards,
> Tomasz Janeczko
> amibroker.com
>
>
> Send BUG REPORTS to bugs@xxxxxxxxxxxxx
> Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
> -----------------------------------------
> Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
> (Web page: http://groups.yahoo.com/group/amiquote/messages/)
> --------------------------------------------
> Check group FAQ at:
> http://groups.yahoo.com/group/amibroker/files/groupfaq.html
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
>
>


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Remanufactured Ink Cartridges & Refill Kits at MyInks.com for: HP $8-20. Epson $3-9, Canon $5-15, Lexmark $4-17. Free s/h over $50 (US & Canada).
http://www.c1tracking.com/l.asp?cid=6351
http://us.click.yahoo.com/0zJuRD/6CvGAA/qnsNAA/GHeqlB/TM
---------------------------------------------------------------------~->

Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/