This statment gets, Invalid statment :RSI
rsi = RSI(close, n);
isDivergenceUp = (rsi > Over_Bought) and (close < high[n]);
isDivergenceDown = (rsi < Over_Sold) and (close > high[n]);
Error here: rsi.AssignValueColor(if rsi > Over_Bought then Color.Red else if rsi < Over_Sold then Color.Green
else if (isDivergenceUp) then
else Color.Yellow);
rsi = RSI(close, n);
isDivergenceUp = (rsi > Over_Bought) and (close < high[n]);
isDivergenceDown = (rsi < Over_Sold) and (close > high[n]);
Error here: rsi.AssignValueColor(if rsi > Over_Bought then Color.Red else if rsi < Over_Sold then Color.Green
else if (isDivergenceUp) then
else Color.Yellow);