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
21 3 4 6

call EikonDesktopDataAPI.dll or EikonOfficeShim.dll from python

Since python eikon is slow for real-time data, can I call EikonDesktopDataAPI.dll or EikonOfficeShim.dll from python? Is there a better way to do it using eikon api?

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.

Upvotes
Accepted
39.4k 77 11 27

You can use some of the Eikon COM APIs in Python, but only in 32-bit Python. See this article for an example. You can use the same technique described in the article with AdfinX Real-Time COM library to subscribe to streaming market data.
To tell if there's "a better way to do it" we need to know what "it" is. Would you care to describe your use case? What is the end goal you're looking to accomplish and what constraints and challenges are you facing?
I wouldn't say that Eikon Data APIs is "slow" for retrieving market data. For snapshot retrieval of market data it's perfectly adequate. What it doesn't do yet is provide capability to retrieve streaming market data. If you need to stream real-time market data, then at the moment you need to use either Eikon COM or Eikon .NET APIs.

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.

Thanks, Alex. My use case is to get futures and swaps real-time data in order to build curve in real-time. I found if I see eikon python API, it took me 3-4 secs to get all the data back through eikon.get_data(...) calls (there are four calls in total). By the way, I can't merge them as they require different fields.

If I go to follow the article you mentioned above, will it be faster?

Any suggestion is welcomed!

Peng

Upvotes
39.4k 77 11 27

If you only need a snapshot of this data and you don't care to receive streaming updates, then retrieving data using Eikon COM or .NET APIs will not necessarily be faster. You don't need to split your data retrieval into several get_data calls. Calling get_data multiple times will indeed linearly increase the retrieval time, because get_data method is executed synchronously. I don't quite understand what you mean when you say you cannot merge the calls because they require different fields. You can retrieve all the fields you need in one call. Some fields may not exist for some instruments. For these RIC/field combinations the resulting dataframe will contain None or NaN.

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.

Good to know. I will try to do so.

Thanks, Alex. I tried it and it is faster than before (half of time saved). But I compare it with excel TR call. In excel function is still much faster. Is there possible I can get similar speed as excel function? I guess it is because of multiprocess/multithread in excel?

While =TR function in Excel and get_data method of Eikon Data APIs use different mechanisms to retrieve a snapshot of real-time record image, I don't see why there would be any noticeable difference in retrieval time between these mechanisms. If indeed there is a difference, it most certainly has nothing to do with multithreading. If you can reliably reproduce this, would you mind laying out the exact replication procedure that I could follow on my end?
Eikon COM and .NET APIs use the same mechanism as =TR function in Excel.

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.