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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
16 0 0 1

How to export portfolio data from Eikon to Python

Client wants to export portfolio data/file from Eikon to Python

eikon-data-apiportfolio
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
23k 22 9 14

Hello @MaeAnthea.Diaz ,

There is no "one API call" approach, please see this previous discussion thread for the detailed information.

1. One approach could be to request the list of instruments from portfolio using EDAPI python, and, also using EDAPI python, to request any available fields on the lust of instruments.

For example, I have portfolio SAMPLE_UK_LRGCORE defined:

port1.gif

2. Another approach could be:

1. From Refinitiv Workspace/Eikon, open Portfolio holdings into Excel

2. From Excel, Save File as CSV-formatted

3. Lastly, using EDAPI python, read CSV into pandas Dataframe the complete holdings from file:

port2.gif


Hope this information helps


port1.gif (24.4 KiB)
port2.gif (22.9 KiB)
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.

@zoya faberov Thank you for the answer. I have sent an email to the client and will wait for her response. Appreciate your help.

@zoya faberov - client responded that it worked, thank you.

Also, client wants to add the quantity and NAV with a date (let's say 18/10/2021 (inception date)

@MaeAnthea.Diaz ,

Quantity, I believe is "Units/PAR". Once they run approach 2, they should see all the content in their portfolio in Eikon.RW exported and imported into DF. I have only screenshotted the small first part of it.

Hi Zoya, my name is Kenneth and and I am asking on behalf of Mae and the Client.

the client had a follow up question.
As per the client.

Thanks for your help, do you have a list with all the fields like 'CF_NAME' (see below):ek.get_data("lists('Adventurer S&E')",['CF_NAME','ASK','BID'])
because "Units/PAR" is not working for example. A list would be really useful.
Upvotes
23k 22 9 14

Hello @KennethCedric.Gonzales and @MaeAnthea.Diaz

I would like to suggest to encourage the client developer to register with developers portal and and use developers forums directly, to search many available answers and participate in questions and discussions directly, as well.

The available fields and how they are populated is specific to the instrument's exchange and market sector. Using Data Item Browser tool allows to examine all available fields:

dib1.gif

, and see which of the fields are available and what values they are populated with:

dib2.gifnext we should be able to request the fields from EDAPI python code.

Additional details and step-by-step on Data Item Browser usage can be found in article Eikon Excel Company Tearsheet in Python (Part 1)

Hope this information helps



dib1.gif (38.1 KiB)
dib2.gif (173.3 KiB)
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