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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
166 10 17 21

Eikon Scripting API: issues with timeseries

Hi all,

The Eikon API 'get_timeseries' function shows unexpected behavior. The 'start_date' is not respected in the following code:

market = [ '.BADI','FXSYSAL=NPX','ENOFBLQH8','ENOFBLYZ8','ENOFBLYZ9','F1BYF8','F1BYF9','F1PQV7','F1PYF8','F1PYF9','ATWQU7','ATWQZ7','ATWYZ8','ATWYZ9','CFI2Z7','CFI2H8','CFI2Z8','CFI2Z9','LCOc1','LCOc2','LCOc3','.OSEBX','.GDAXI','.SSEC','.AXJO','.FTSEE','EUR=X','NOK=X','GBP=X','/.DXY','/.BADI','SKMELYH8','SKMELYH9',]

df = eikon.get_timeseries(market,
                          fields=["Close"], start_date = "2016-03-01", 
                          interval="daily")
df

Furthermore, there is no error message when hitting the 3,000 output limit. So the output (of 7 instruments * 472 rows = 3302) results looks like this:

While the output of 5 instruments * 472 rows = 2460 looks like this:

Can we please get error message instead of populating the output with NaNs?

Thanks for your help!

eikoneikon-data-apiworkspaceworkspace-data-apirefinitiv-dataplatform-eikonpythontime-series
timeserie-bad.png (13.2 KiB)
timeserie-good.jpg (18.0 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.

Upvotes
Accepted
39.2k 75 11 27

The problem as I see it is the shared 3K rows limit, which is the reason for both the timeseries returned not stretching back to 01-Mar-2016 when you send 33 RICs in a single request, and for some rows for some instruments being returned as NaN when 3K divided by the number of RICs does not result in an integer.

The 3K limit issue has already been raised here and reported to development and product management:
https://community.developers.refinitiv.com/questions/6355/bug-in-get-timeseries.html

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.

Thanks Alex. That would mean that when the 3K limit issue has been fixed, the issue with NaNs wouldn't be applicable anymore, right?

Right. I'm not sure what the plan is for addressing this issue, but personally I would consider anything short of increasing the limit to at least 50K rows per RIC (not shared by all RICs in the request) to be unsatisfactory. Any solution that does not allow one to retrieve at least 50K rows for each RIC in the request would be deficient compared to capabilities available through legacy Eikon APIs.

So the second problem will persist when we keep a shared limit, but would just be moved... Any way we can produce warning messages from server side?

Show more comments
Upvotes
4.6k 26 7 22

@Joris.Hoendervangers

I guess that the date is ignored, because you are hitting the limit. Here is a handy function to check if your are okay:

from datetime import date
from numpy import busday_count

def number_of_points(instruments, start_date, end_date=0):
    days = busday_count(start_date, date.today() if end_date==0 else end_date)
    return len(instruments)*days

Based on your request, the number of points is 11583 instead of the 3000 limit, as the number of instruments on your market list is 33.

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.

Thanks Zhenya. I understand it is because of the 3000 limit, but this makes it error prone, so we would like to see an error message instead.

Upvotes
1 1 1 2

@ Zhenya Kovalyov

@Joris.Hoendervangers

Could you help explain the means for 3000 points limitation.

Is it means that we can't get data more than 3000 at one time ?

If store data to excel, it's limit to get 3000 cell data at a time?

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.

The response to any single get_timeseries request for interday timeseries interval is limited to 3K rows. That is you will never get more than 3K rows of timeseries data when you execute get_timeseries method no matter what parameters you use. If get_timeseries uses a list of RICs, the 3K limit is shared. I.e. if you pass 10 RICs to get_timeseries method the total response is limited to 3K rows or 300 rows per RIC.

This is a very unfortunate limit of the timeseries Web service behind Eikon Data API. RHistory function of Eikon Excel or Eikon .NET API use different Web service to retrieve timeseries, which is not subject to this limit. The most unfortunate part is that the limit is shared between RICs in the same request. Hopefully one day the limits will be improved. Until then you can execute get_timeseries requests for one RIC at a time, although in this case you'll be subject to another limit: the throttle allowing the requests to be sent with a max frequency of 3 requests per second.

Would it be possible to produce some error messages until this has been solved? I would say the confusion is more of an issue than the actual limit itself.

Upvotes
84 3 0 6

@Alex Putkov. Is this 3000 limit going to remain when the API is out of beta?

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