Data provided by Kite API during Market Time is incorrect

shahrukhkhan489
I have observed that while fetching data from Zerodha API, using the historical data call it returns incorrect values.
data = pd.DataFrame(kite.historical_data(instrument,dt.date.today()-dt.timedelta(duration), dt.date.today(),interval))

Have observed that there was an incorrect decision being taken by the Deployed Algorithm. After through Analysis/debugging found out that the issue is with the Data being retrieved using Zerodha API was incorrect



eg:

For AXISBANK close price retrieved

1. During the market time - 5-minute candle
Data at 2020-08-17 09:15:23.536229 - 2020-08-17 09:15:00+05:30  439.45
Data at 2020-08-17 09:18:33.982637 - 2020-08-17 09:15:00+05:30 434.15
2. After Market hours data on cross-checking values

After Market hours data - 2020-08-17 09:15:00+05:30 439.1
For HDFC close price retrieved

1. During the market time - 5-minute candle

Data at 2020-08-17 12:33:32.760533 - 2020-08-17 12:30:00+05:30 1796.85
Data at 2020-08-17 13:58:33.903983 - 2020-08-17 13:55:00+05:30 1796.1
2. After Market hours data on cross-checking values
After Market hours data            - 2020-08-17 12:30:00+05:30	1791.75
- 2020-08-17 13:55:00+05:30 1796.95
Any such experience earlier with Zerodha. Should we consider alternative sources as this is causing incorrect decisions by the deployed algorithm?
  • sujith
    The historical data API is provided for backtesting purposes only. It is not recommended to use for live market strategies.
    You can check out this thread to know more.
Sign In or Register to comment.