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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
97 2 4 10

eikon data api passing parameter

ric=['7207.T']

fields = ['TR.GICSSector', 'TR.GICSIndustry', 'TR.ClosePrice', 'CF_CURR', 'TR.CompanyMarketCap']

params={'TR.CompanyMarketCap': {'CURN':'USD'}}

ndata = eikon_data.get_data( rics, fields,params);
 
               

Could you help me with passing arguments to get_data function? For example, I'd like marketcap in USD and above code does not work.

eikoneikon-data-apiworkspaceworkspace-data-apirefinitiv-dataplatform-eikonpythonparameters
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.

Upvotes
Accepted
39.2k 75 11 27
  • 7207.T is not a valid RIC.
  • To apply CURN parameter only to TR.CompanyMarketCap use
ek.get_data('7201.T',['TR.GICSSector', 'TR.GICSIndustry', 'TR.ClosePrice',
                      'CF_CURR', 'TR.CompanyMarketCap(CURN=USD)'])

To apply CURN parameter only to all fields which accept this parameter (in this case it will be TR.ClosePrice and TR.CompanyMarketCap) use

ek.get_data('7201.T',['TR.GICSSector', 'TR.GICSIndustry', 'TR.ClosePrice',
                      'CF_CURR', 'TR.CompanyMarketCap'],{'CURN':'USD'})
  • Check out this tutorial, which talks at length about finding metadata (field names and parameters) for use with Eikon Data APIs.
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.

Upvotes
97 2 4 10

thank you!

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