wrong historical data sometime

monikanareshkumar
I am running algo using zerodha API. Entry conditions are as follows: for buying:- previous close (5 Minute) > previous close candle supertrend (5 Minute) and previous close (5 Minute) > previous close candle vwap (5 Minute) and previous close(5 Minute) > previous close candle EMA50 (5 Minute) buying exit: - previous close (5 Minute) previous close candle supertrend(5 Minute) or previous close (5 Minute) > previous close candle vwap (5 Minute) or previous close(5 Minute) > previous close candle EMA50(5 Minute) Now I am getting wrong historical data sometime due to which got out from trades. Today exited from buying trades in TCS at 09:25 then exited from buying trades in TCS at 09:50 thereafter exited from buying trades in TCS at 10:05. These trades were got wrong data (previous close) 1 time today due to entry and exit occurred before 5 minute candle close. Entry and exit were taken only on 5 minute close, in-between there should not be any action in algo strategy. Algo is failing due to wrong data. I am repeatedly getting this problem since last week. Now I am sure that I got last close candle data wrong by printing its value on entry and exit conditions. Please look into it.
  • monikanareshkumar
    These fluctuations are random and very less but due to these fluactions i got out from trade even exit criteria doesn't satified in-between 5 minute interval.
  • sujith
    @monikanareshkumar,
    The historical data provided by Kite Connect are for backtesting purposes only. You need to generate candles at your end using the live market data provided on the Websockets API.

    You can get started here.
  • monikanareshkumar
    There is no meaning of paying zerodha for historical data if I have to convert live data into historical data.
    Zerodha is the best stock broker which everybody knows but instead of resolving the issue you are telling me that historical data is only for back testing purpose only.
    What's the surety the historical data we get for back testing is right/correct ?
  • monikanareshkumar
    I am still waiting for Zerodha response.
Sign In or Register to comment.