Stochastic RSI Indicator For Amibroker

Stochastic RSI Indicator For Amibroker
 

//www.aflcode.com
PeriodRSI = Param( "PeriodRSI", 13, 1, 250, 1 );
PeriodStoch = Param( "PeriodStoch", 8, 1, 250, 1 );
MAType = Param( "MAType", 1, 1, 2, 1 );
PeriodSK = Param( "PeriodSK", 5, 1, 250, 1 );
PeriodSD = Param( "PeriodSD", 3, 1, 250, 1 );
Upper = Param( "Upper", 70, 50, 100, 1 );
Lower = Param( "Lower", 30, 0, 50, 1 );

irsi = RSI( PeriodRSI );
llvRsi = LLV( irsi, PeriodStoch );
hhvRsi = HHV( irsi, PeriodStoch );

StoRSI = 100 * ((irsi- llvRsi) / Max(hhvRsi - llvRsi, 0.0001));

if( MAType == 1 )
{
    SK = MA( StoRSI, PeriodSK );
    SD = MA( SK, PeriodSD );
}

if( MAType == 2 )
{
    SK = EMA( StoRSI, PeriodSK );
    SD = EMA( SK, PeriodSD );
}

Plot( SK, "DTOscSK", ParamColor( "ColorSK", colorBlueGrey ), styleLine );
Plot( SD, "DTOscSD", ParamColor( "ColorSD", colorWhite ), styleDashed );
Plot( 0, "ZeroLine", ParamColor( "ColorZero", colorWhite ), styleLine );
Plot( Upper, "Upper", ParamColor( "ColorUpper", colorRed ), styleLine );
Plot( Lower, "Lower", ParamColor( "ColorLower", colorGreen ), styleLine );

4 thoughts on “Stochastic RSI Indicator For Amibroker”

    1. 15 min time frame would be the best for this stochastic RSI indicator. It works great with forex and commodity market. I haven’t tried it yet with cash and future market. If anybody did, then please let us know.

       
  1. Wow, awesome blog layout! How long have you been blogging for?

    you made blogging look easy. The overall look of your web site is great, let alone
    the content!

     

Leave a Reply

Your email address will not be published. Required fields are marked *