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
1 0 0 1

Field for currency in timeseries

Hi, I'm using Eikon to pull data into Python. This is the line I use to pull data:

ek.get_timeseries(sym,start_date='2016-03-03',end_date= sheet['B4'].value, interval = 'daily')['CLOSE']

where 'sym' is a variable for RIC that keeps changing. The RICs I'm using all have different currencies. I was wondering if there was a way to define the currency in which I want the data to be pulled within the timeseries function or if there was any other way to do this. Thanks!

eikoneikon-data-apipythonrefinitiv-dataplatform-eikonworkspaceworkspace-data-apitime-series
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.

Hi @mchoudhary0,

I don't understand what you are trying to do. The mechanism to fetch the daily timeseries value for the different currencies is correct. Can you elaborate?

Please be informed that a reply has been verified as correct in answering the question, and has been marked as such.

Thanks,

AHS

1 Answer

· Write an Answer
Upvotes
Accepted
39.4k 77 11 27

get_timeseries method can only return price history in the currency in which the instrument is traded. If your instruments are stocks or indices you can use get_data method with TR.PriceClose field, which can return price history in the currency of your choice:

ek.get_data('AAPL.O',['TR.PriceClose.date;TR.PriceClose'],
           {'SDate':'2019-05-01', 'EDate':'2019-07-01', 'CURN':'JPY'})
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.

What if I want monthly data instead of daily data using ek.get_data? What should I do with the above command? Thanks a lot.

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.