Hi,
Below is one formula for Reverse Engineering RSI which I have picked up from
this group.
Now, the formula currently resolves value of 39.82 for the RSI and plots on the
chart. In the same manner, I need other values of RSI namely 50 and 65 to be
plotted on the same chart.
I tried changing the values, but it is not working.
Somebody please help.
////////////////////////////////
// Reverse Engineer RSI
////////////////////////////////
Value = Param("RSI value", 39.82, 1, 100, 0.1 );
WildPer = Param("Time periods", 14, 1, 100 );
ExpPer = 2 * WildPer - 1;
AUC = EMA( Max( C - Ref( C, -1 ), 0 ), ExpPer );
ADC = EMA( Max( Ref( C, -1 ) - C, 0 ), ExpPer );
x = (WildPer - 1) * ( ADC * Value / (100-Value) - AUC);
RevEngRSI = IIf( x >= 0, C + x, C + x * (100-Value)/Value );
Plot( Close, Date()+", Close ", colorBlack, styleCandle );
Plot( RevEngRSI,
"Reverse Eng. RSI( "+WriteVal(WildPer,1.0)+", "+
WriteVal(Value, 1.2)+" )",
colorGreen );
Rgds
Mithil