I notice get_data gives different return (shifted data) when the duration is large (eg. 1400 days)
This can be reproduced with below:
- The current date is 28 Jul 2019.
- 27-28 Jul 2019 is none trading day.
- The last row of return result is NA, no timestamp, BUT with a value of PE.
- However, the PE value of last row (no timestamp) is for second last row (26 July).
df, error = ek.get_data( 'AIRX.KL', ['TR.OPENPRICE.Date','TR.OPENPRICE','TR.HIGHPRICE','TR.LOWPRICE', 'TR.CLOSEPRICE','TR.PE','TR.VOLUME','TR.BIDPRICE','TR.ASKPRICE'], parameters = { 'SDate': -1400, 'EDate': 0})
When I run this the same code (with smaller date window, just 5 days), the data is show correctly.
df, error = ek.get_data( 'AIRX.KL', ['TR.OPENPRICE.Date','TR.OPENPRICE','TR.HIGHPRICE','TR.LOWPRICE', 'TR.CLOSEPRICE','TR.PE','TR.VOLUME','TR.BIDPRICE','TR.ASKPRICE'], parameters = { 'SDate': -5, 'EDate': 0})
Is this a correct behaviour ?