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
23 0 6 7

COT report using EIkon API

Hi,


I am trying to access the commitment of traders report for a market. The code I have used is follows:


data, err = e.get_data(["SB"], ["TR.COTR"],

{'SDate':str(dt.datetime.now().date()-dt.timedelta(days=14)),'EDate':str(dt.datetime.now().date()) })


The Error message is as follows:

'message': 'The formula must contain at least one field or function.',


I tried changing the TR.COTR with COTR and got the following message:

'message': "Error: Field 'COTR' was not found in response for the instrument 'SB'",


Please let me know how this data can be accessed. Thank you.

eikoneikon-data-apipythonrefinitiv-dataplatform-eikonworkspaceworkspace-data-api
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 @varun.divakar,

Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query?

If yes, please click the 'Accept' text next to the reply. This will guide all community members who have a similar question. Otherwise please post again offering further insight into your question.

Thanks,

AHS

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
18.2k 21 13 21

Hi @varun.divakar

COTR or TR.COTR fields are not a valid field for SB ric code.

You can use Data Item Browser (type in DIB on Eikon to launch this app) to explore what fields are available.


You can also contact the Refinitiv Content Helpdesk at https://my.refinitiv.com/ to get help on the content such as if this field is available? if so, what is the field name.



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.