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
3 0 0 2

Unable to get all available periods when requesting multiply time series using eikon for python.

I am currently trying to get the data for multiple time series between the year 1995 and now at a monthly level.


rics = 
['aPLCEMPO/A',
'aPLCPIB',
 'aPLNOT/C',
 'aPLHPERMCP',
 'aPLRETTOS/CA',
 'aPLUNR',
 'aPLCINDG/A',
 'aPLPPIAT/C',
 'aPLWSTOTH/C',
 'aPLCONACT',
 'aPLIMPP',
 'aPLEXPP',
 'aPLCPICXFE',
 'aPLBINTR',
 'aPLXRUSD']

eikon_df_m = ek.get_timeseries(rics, interval = 'monthly', start_date = '1995-01-01')

It returns missing data on quite a few of them where there is data and the earliest it goes back is 2006, however when requesting them individually I can get data going back as far as I want.


Basically very few of the rows below should be NA and data should go back to 1995 for quite a few of selected seris.


1678119174651.png

eikoneikon-data-apipythonrefinitiv-dataplatform-eikonworkspace#technology#contentpython apitime-series
1678119174651.png (129.6 KiB)
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.

1 Answer

· Write an Answer
Upvote
Accepted
10.2k 18 6 9

@sassoonj Thanks for your question and sorry to hear about your issue. So I believe you are running into get_timeseries interday limit per call of 3000 data points, To get around this please try iterating across the list of RICs as follows:

rics = ['aPLCEMPO/A','aPLCPIB','aPLNOT/C','aPLHPERMCP','aPLRETTOS/CA','aPLUNR',
        'aPLCINDG/A','aPLPPIAT/C','aPLWSTOTH/C','aPLCONACT','aPLIMPP','aPLEXPP',
        'aPLCPICXFE','aPLBINTR','aPLXRUSD']
data1 = pd.DataFrame()
 
for ric in rics:
    df1 = ek.get_timeseries(ric,interval = 'monthly', start_date = '1995-01-01')
    df1.rename(columns = {'VALUE': ric}, inplace = True)
    if len(data1):
        data1 = pd.concat([data1, df1], axis=1)
    else:
        data1 = df1

data1

1678125449156.png

This seems to work for me. I hope this can help.


1678125449156.png (268.6 KiB)
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.

Thank you, this works. Although I think there is an error in your answer. I changed

df1.rename(columns = {'VALUE': i}, inplace = True) 
to:
df1.rename(columns = {'VALUE': ric}, inplace = True) 
@sassoonj Thanks so much for the spot - apols yes - I have changed the code sample I shared.

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.