
RSI indicator throws following exceptions:
23:16:16 Error in indicator: java.lang.ArrayIndexOutOfBoundsException: 396 @ com.dukascopy.api.impl.ai.calculate(Unknown Source)
...
22:43:20 Error in indicator: calculate() method of indicator [RSI] returned less values than expected. Requested from-to [0]-[410], input array size [411], returned first calculated index [38], number of calculated values [373], lookback [37], lookforward [0], expected number of elements is [374]
public void onTick(Instrument instrument, ITick tick) throws JFException {
....
double rsi = indicators.rsi(instrument, DEFAULT_PERIOD, OfferSide.BID, IIndicators.AppliedPrice.MEDIAN_PRICE, 14, 0);
...
}
Today the same happend to the stochastic indicator:
08:37:12 Error in indicator: java.lang.ArrayIndexOutOfBoundsException
08:37:11 Error in indicator: calculate() method of indicator [STOCH] returned less values than expected. Requested from-to [0]-[145], input array size [146], returned first calculated index [36], number of calculated values [110], lookback [29], lookforward [0], expected number of elements is [117]
...
08:13:38 Error in indicator: java.lang.ArrayIndexOutOfBoundsException
08:13:38 Error in indicator: java.lang.ArrayIndexOutOfBoundsException: 141 @ com.dukascopy.indicators.StochasticIndicator.calculate(StochasticIndicator.java:98)