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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
1 0 0 0

ek.get_data concern

Hi I am using the python API. I see the syntax to pull a screen based on criteria using ek.get_data(["SCREEN(... How can I do this as of particular historical dates?

eikoneikon-data-apiworkspaceworkspace-data-apirefinitiv-dataplatform-eikonpython
icon clock
10 |1500

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

1 Answer

Upvotes
Accepted
39.2k 75 11 27

Fields that provide historical data can be used in the Screener to screen on values as of a historical date by adding field level SDate parameter to the expression. E.g. the following expression retrieves all active stocks of companies headquartered in the US that had market cap over USD 1 trln as of 2020-01-01.

ek.get_data('SCREEN(U(IN(Equity(active,public,primary))),' + 
            'TR.CompanyMarketCap(SDate=20200101)>=1000000000000,' +
            'IN(TR.HQCountryCode,"US"), CURN=USD)',
            ['TR.CommonName','TR.CompanyMarketCap(SDate=20200101)'])

Note that the fields that don't provide historical data can only be used to screen on the current value. In the above example the screener will return all stocks of companies currently headquartered in the US that had market cap over USD 1trln on 2020-01-01.

icon clock
10 |1500

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

Click below to post an Idea Post Idea