I am running a script in which I calculate the OHLCV data based upon the live tick data through WebSocket. The code writes the incoming tick onto a local db and subsequently reads whenever a new candle has been created. It has been created using various FAQs posted on the forum itself - https://kite.trade/forum/discussion/2604/convert-ticks-to-candle
The candles are formed using the LTP of the instrument. I am attaching 2 csv files containing the ltp and cumulative volume, the first one containing data as processed by each tick and secondly the candles formed by the tick data.
The instrument in Nifty October Futures.
As one can see the candles using the historical API and shown on charts is vastly different. The opening itself has a massive difference of 7 points.
Can anyone confirm whether the tick data received was right?
If the problem is common what is the solution to the following? I am willing to share the code which stores the ticks and subsequently reads them.