Hello,
First of all, thanks a lot for this API that is helping us a lot in our daily work.
We are using the get_timeseries to retrieve historical closing prices for different products, and we stumbled upon a weird behaviour.
When we query the method with a start_date and end_date which are holidays (week-ends or official closed days), we get a lot of results instead of an empty Dataframe.
For example :
> python
Python 3.5.2 (v3.5.2:4def2a2901a5, Jun 25 2016, 22:01:18) [MSC v.1900 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import eikon as ek
>>> import datetime as dt
>>> ek.set_app_id('TRUNCATED')
>>> ek.get_timeseries('UEN.L', start_date=dt.datetime(year=2017,month=1,day=1), end_date=dt.datetime(year=2017,month=1,day=2))
UEN.L HIGH LOW CLOSE OPEN COUNT VOLUME
Date
2006-02-21 7750.00 7700.00 7700.0 7750.0 -1.0 10551.30
2006-02-22 7700.00 7400.00 7550.0 7700.0 -1.0 10163.20
2006-02-23 7550.00 7550.00 7550.0 7550.0 -1.0 2772.00
2006-02-24 7550.00 7550.00 7550.0 7550.0 -1.0 908.55
2006-02-27 7800.00 7550.00 7800.0 7550.0 -1.0 5851.05
[...]
2018-01-03 60.00 58.20 60.0 60.0 2.0 7600.00
2018-01-04 NaN NaN NaN 60.0 -1.0 NaN
As you can see, we receive a full DataFrame of 3000 rows, which I guess is the max results you can provide in one call.
Changing the end_date with a date that is not a holiday gives us the expected result :
>>> ek.get_timeseries('UEN.L', start_date=dt.datetime(year=2017,month=1,day=1), end_date=dt.datetime(year=2017,month=1,day=3))
UEN.L HIGH LOW CLOSE OPEN COUNT VOLUME
Date
2017-01-03 73.88 64.0 67.5 65.0 7.0 12893.3
Doing the same calls with strings instead of datetime gives the same results.
Is it an expected behaviour on your side ?
Thanks in advance,
Grégoire Bärtschi