Upgrade from Eikon -> Workspace. Learn about programming differences.

For a deeper look into our Eikon Data API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
104 8 10 13

eikonapir: how to get timeseries data for dividends field?

Hello,

I'm trying the R interface API using eikonrapi and I can successfully download timeseries of stock prices and volumes. I'd like to be able to get the dividend history of a stock but using the get_data() command gets me only the last instance and using the get_timeseries() only has these fields:

TIMESTAMP HIGH CLOSE LOW OPEN COUNT VOLUME N

as fields available (shown using "*"). How can I combine the 2 commands?

In Excel add-inn this is achieved through a TR commmand like:

=TR(XXX,"TR.DivExDate;TR.DivAdjustedGross;TR.DivCurr","DateType=XD SDate=#XX EDate=XX",XX,XX,XX)

thanks,

Claudiu

eikoneikon-data-apipythonrefinitiv-dataplatform-eikonworkspaceworkspace-data-apitime-seriesreikon-data-api-r
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
Accepted
39.4k 77 11 27

Hi @claudiu

The following function retrieves dividends for IBM between 1-Jan-2016 and today's date:

get_data("IBM",list('TR.DivExDate','TR.DivAdjustedGross','TR.DivCurr'),list('DateType'='XD','SDate'='1D','EDate'='2016-01-01'))

I hope it helps.

Alex

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Thanks, works. Would be great if the documentation is updated to include these fields.

Upvotes
104 8 10 13

The answer from Alex worked till lately. It doesn't seem to work anymore, see below. Something in the interface changed?

>get_data("IBM",list("TR.DivExDate","TR.DivAdjustedGross","TR.DivCurr"),list('DateType'='XD','SDate'='1D','EDate'='2016-01-01'))

data frame with 0 columns and 0 rows

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

I don't believe there's been any changes, and I have no problem executing this call on my end. You didn't by any chance forget to execute set_app_id method prior to calling get_data?

Upvotes
17.1k 80 39 63

Hi @claudiu,

Within Python, using the equivalent call, I'm seeing this:

Are you able to confirm the same results using Python? Because the R implementation is not officially supported and is open source, you can verify if anything within this interface has changed.


ahs.png (15.8 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
104 8 10 13

Resolved. Today same program works. Yesterday the get_timeseries() commands worked (so the app_id was set correctly) while the get_data() ones failed. Maybe a temporary glitch with the Eikon server interface. Thanks for the responses.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.