RSI Sensitivity

 

Hello everyone,


I have modified RSI MQ4 file provided by Metaquotes to calculate and draw RSI rate of change (Let's call it RSI Sensitivity). What I need to calculate follows:


RSISen[i] = (RSI[i]-RSI[i-1])/(Close[i]-Close[i-1])


I have done everything according to the book. But I can't get a line (It draws nothing). Can anyone tell me what has gone wrong?


MQ4 file has been attached.

Files:
 
#property indicator_separate_window
//#property indicator_minimum    0
//#property indicator_maximum    100
#property indicator_buffers    1
#property indicator_color1     DodgerBlue
//#property indicator_level1     30.0
//#property indicator_level2     50.0
//#property indicator_level3     70.0
#property indicator_levelcolor clrSilver
#property indicator_levelstyle STYLE_DOT

Line 192-

 //if (i>1)
 //   ExtRSISenBuffer[i-1]=(ExtRSIBuffer[i]-ExtRSIBuffer[i-1])/(Close[i]-Close[i-1]);
 if (i>InpRSIPeriod && close[i]-close[i-1]!=0.0)
    ExtRSISenBuffer[i]=(ExtRSIBuffer[i]-ExtRSIBuffer[i-1])/(close[i]-close[i-1]);
 else
    ExtRSISenBuffer[i]=0.0; //I don't know exactly.
      

I do not know if this display is correct or not, because I do not know "RSI Sensitivity".

 
Naguisa Unada:

Line 192-

I do not know if this display is correct or not, because I do not know "RSI Sensitivity".

You are the best Naguisa! I hope this the beginning of a mutual and constructive cooperation.

I have another question. Does this forum has any "thank You" button or something?

 
I think maybe there is no such a function.
 
Keep the modification suggested by Naguisa but i would change the formula to this :

RSISen[i] = (RSI[i+2]-RSI[i+1])/(Close[i+2]-Close[i+1])
 
Lorentzos Roussos :
Keep the modification suggested by Naguisa but i would change the formula to this :

RSISen[i] = (RSI[i+2]-RSI[i+1])/(Close[i+2]-Close[i+1])

Why?

In this case, the array series is false.

  ArraySetAsSeries(ExtRSISenBuffer,false);
   ArraySetAsSeries(ExtRSIBuffer,false);
   ArraySetAsSeries(ExtPosBuffer,false);
   ArraySetAsSeries(ExtNegBuffer,false);
   ArraySetAsSeries(close,false);
   ArraySetAsSeries(open,false);
   ArraySetAsSeries(high,false);
   ArraySetAsSeries(low,false);

So ( i + 1) and ( i + 2) mean the future values.