Historical Data issue

AnkitDoshi
Hi,
Sometimes when I try to fetch data using kite.historical, I get empty data list.
What am i doing wrong.

"""
In [96]: interval='30minute'

In [97]: from_date='2016-11-20'

In [98]: to_date='2016-11-28'

In [99]: instrument_token='53373959' # CrudeOil futures

In [100]: crudeoil=kite.historical(instrument_token,from_date,to_date,interval)

In [101]: crudeoil

Out[101]: []

"""


Also,
Why is it essential to write "to_date"?
It should be, if to_date not mentioned it should take data till date

  • sujith
    Hi @AnkitDoshi,
    What symbol are you looking for?
  • AnkitDoshi
    instrument_token expiry lot_size name tradingsymbol

    53373703 2016-12-19 1 CRUDEOIL DEC JAN 2017 CRDDECJA1716DECFUT


    First I looked for Mini Crudeoil, than the above one.
    Still I get same error
  • Matti
    @AnkitDoshi CRDDECJA1716DECFUT is the symbol for the spread contract. You can't place trades for this via Kite. For Crude Oil, you should be looking at CRUDEOIL16DECFUT and CRUDEOILM16DECFUT for the mini contract. The full list of symbols is given in this thread. The symbols mentioning 2 months are essentially spread contracts that cannot be traded from Kite. We'll try to make the spread contracts available in the future.
  • AnkitDoshi
    Ohh.. I m sorry. Thanks Mate
This discussion has been closed.