Simple question about RSI

 

Hello everyone!

I know how to say " If RSI > x  , then do this"

But, how to say     "If  RSI > x when candle is closed then do this" ( I mean the last candle ) 


Thanks for your help. Have a good day :)

 
double RSI=iRSI(Symbol(),PERIOD_H1,2,PRICE_CLOSE,1);// the last number in this case 1 is the last candle
in you declaration of the Rsi if you put as last value 0 it means the current candle , if you put 1 it means the one before that
 
Maria Erica Costagliola:
in you declaration of the Rsi if you put as last value 0 it means the current candle , if you put 1 it means the one before that

Thanks for your help :) I am grateful

Reason: