Websockets(python) not deliver ohlc data correctly

dharmaraj81
hi,

i recently subscribed for historical data, but still i am not getting ohlc data correctly, it delivering that day opening price, low price, high price, and close price only. it will be same in all tick data..

Token LTP Trade Volume Open High Low Close \
2019-11-04 11:06:03 895745 420.30 14775212 403.0 421.7 403.0 399.5
2019-11-04 11:06:04 895745 420.25 14775757 403.0 421.7 403.0 399.5
2019-11-04 11:06:05 895745 420.30 14776120 403.0 421.7 403.0 399.5

i need every trigger ohlc data. any suggestion ??
Thanks Advance
Dharma
Tagged:
  • sujith
    Though the historical data provides intraday candle data. We recommend using it only for backtesting purpose only. For live strategies, we suggest generating at your end using the live market data.

    You can get started here.
  • dharmaraj81
    Thanks Sujith,

    i am getting live marget data using websockets, but all the ticks have same ohlc data like follow

    Token LTP Trade Vol Open High Low Close
    2019-11-04 11:06:03 895745 420.30 14775212 403.0 421.7 403.0 399.5
    2019-11-04 11:06:04 895745 420.25 14775757 403.0 421.7 403.0 399.5
    2019-11-04 11:06:05 895745 420.30 14776120 403.0 421.7 403.0 399.5

    Thanks
  • rakeshr
    @dharmaraj81
    i recently subscribe for historical data, but still i am getting ohlc data with wrong, it delivering that day opening price, low price, high price, and close price only. it will be same in all tick data.
    Historical data is used to fetch required period candle OHLC data, not every tick OHLC. As you are requesting for day's candle data, you will get day's candle OHLC data as above.Go through this documentation to know, about historical candle data.
    i need every trigger ohlc data. any suggestion ??
    By every trigger, you mean every tick?
    You can use Webosocket streaming, refer to this documentation.
  • dharmaraj81
    Hi @rakeshr

    i am using websocket streaming only... yes, i mean tick, but all ticks have same ohlc data

    thanks
  • dharmaraj81
    Hi @sujith

    i am using Python websocket streaming, so i can get live data as tick,

    but my problem is, all tick have same ohlc data

    pls help me to resolve it

    thanks
    Dharma
  • dharmaraj81
    Anther sample ticker data

    Token LTP Trade Volume Open High Low Close \
    2019-11-04 12:05:08 895745 412.75 17712402 403.0 421.7 403.0 399.5
    2019-11-04 12:05:09 895745 412.80 17712402 403.0 421.7 403.0 399.5
    2019-11-04 12:05:14 895745 412.60 17730173 403.0 421.7 403.0 399.5
  • rakeshr
    @dharmaraj81
    but my problem is, all tick have same ohlc data
    OHLC is always shown for the whole day in Websocket streaming.
    Tick data means market data that shows price and volume at every print, it also data about change to the best bid and ask. So, there can't be OHLC for every tick, as OHLC is formed for a required time frame not just of a tick.
  • dharmaraj81
    Hi @rakeshr

    sorry i dont know about it, anyway thanks to teach me

    :)
This discussion has been closed.