I am currently collecting data of all constituents of the CDAX index. If requesting fields like Close Price, Company Market Cap etc., then every time data is received, it is correct, including values, correct column names etc.
When I added different fields like for example Percent Held by Strategic Entities (InstrPctHldStrategic) then if long timeranges are requested, nearly all of the time the data has all NaN-values. Even for the columns that were previously received without any issues. Additionally the column names do not have their 'normal-language' names (TR.CLOSEPRICE -> Close Price), but are all named with the field-parameter names (TR.CLOSEPRICE etc.).
I tested this on many timeframes. For short ones (one year, monthly data) there is quite a high chance that the response will be correct.
For longer timeframes I could not get one single correct answer. My guess first was, that data for fields like InstrPctHldStrategic is not available for the requested timeframe, and therefore such error occurs, but testing on short timeframes, I saw, that one request could result in a correct answer, but sending the same exact request 2 min later, results in a wrong answer again.
My second guess would be server issues. Are there currently any problems?
Checkout the code which resulted in mostly bad formed results:
symbols = ek.get_data(self.index_chain, 'TR.RIC')[0]['RIC'].tolist()
df = ek.get_data(symbols,
fields = ['TR.CLOSEPRICE.date', 'TR.CLOSEPRICE', 'TR.CompanyMarketCap', 'TR.InstrPctHldStrategic', 'TR.FreeFloatPct'],
{'SDate': '2015-11-30', 'EDate': '2020-11-30', 'Frq': 'AM'})[0]
return:
0 TR.CLOSEPRICE.DATE TR.CLOSEPRICE TR.COMPANYMARKETCAP TR.INSTRPCTHLDSTRATEGIC TR.FREEFLOATPCT
0 GSC1n.DE <NA> <NA> <NA> <NA> <NA>
1 ELBG.DE <NA> <NA> <NA> <NA> <NA>
2 DICn.DE <NA> <NA> <NA> <NA> <NA>
3 TLIk.DE <NA> <NA> <NA> <NA> <NA>
4 SZUG.DE <NA> <NA> <NA> <NA> <NA>
.. ... ... ... ... ... ...
402 MSHGn.F <NA> <NA> <NA> <NA> <NA>
403 IFXGn.DE <NA> <NA> <NA> <NA> <NA>
404 COP1n.DE <NA> <NA> <NA> <NA> <NA>
405 AOXG.DE <NA> <NA> <NA> <NA> <NA>
406 FKEK.F <NA> <NA> <NA> <NA> <NA>
Format of correct return (achieved with same request for different timeframe):
Instrument Date Close Price Company Market Cap Percent of Shares Held by Strategic Entities Free Float (Percent)
0 GSC1n.DE 2019-12-30T00:00:00Z 18.86 2.009643e+08 13.7117 71.8883
1 GSC1n.DE 2020-01-31T00:00:00Z 19.00 2.044330e+08 13.7117 71.8883
2 GSC1n.DE 2020-02-28T00:00:00Z 18.78 2.072512e+08 13.7117 71.8883
3 GSC1n.DE 2020-03-31T00:00:00Z 13.66 2.035658e+08 13.7117 71.8883
4 GSC1n.DE 2020-04-30T00:00:00Z 15.55 1.452493e+08 13.7117 71.8883
... ... ... ... ... ... ...