[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RSI Osc Indicator



PureBytes Links

Trading Reference Links

Trying to convert from Metastock into TS2000i.  Here's what I have so
far but as you will see it's too smooth. 
I think I might need a counter for the summation of up / down closes or
I'm supposed to use an 
AverageTrueRange for the RSI, don't know how I would do that yet,
instead I just use an average. 

{ Metastock }
=============================================================
 RSI Derivative Oscillator

 Part1:=
 2.3*{the average true range of ("RSI 14,6,S") up closes} If({"RSI
 14,6,S=up"} Mov(RSI(14),6,S)> Ref(Mov(RSI(14),6,S),-1){=true}, 
 {then}ATR(1), {else}0);

 Part2:=
 2.1*{the average true range of ("RSI 14,6,S") down closes} If({"RSI
 14,6,S=down"} Mov(RSI(14),6,S)<
 Ref(Mov(RSI(14),6,S),-1){=true},
 {then}ATR(1),
 {else}0);

 Part3:=
 {RSI 14 added with Part1 + Part2} RSI(14)+Sum(Part1,14)+Sum(Part2,14);

 RSIDerivOsc:=
 {The 15 unit triple smoothed Part3}
 Mov(Mov(Mov(Part3,15,S),15,S),15,S);
 RSIDerivOsc

 ============================================================

{ Cut and Paste into TS2000i as a new indicator : } 
======================================================================

{RSI Derivative Index  - created by Thomas J, Festa, CMT Copyright c
2007 }
	
Inputs: Price(Close), RSILgth(14), AvgLgth(6), RSIDerivOscLgth(15);
	
Vars: RSIDerivOsc(0);
		
{ Part1:= 2.3 * the average true range of ("RSI 14,6,S") up closes }

If Average(RSI(Price, RSILgth), AvgLgth) > Average(RSI(Price, RSILgth),
AvgLgth)[1] then
	Value1 = 2.3 * Average(RSI(Price, RSILgth), AvgLgth)
else
	Value1 = 0;

{ Part2:= 2.1 * the average true range of ("RSI 14,6,S") down closes } 

If Average(RSI(Price, RSILgth), AvgLgth) < Average(RSI(Price, RSILgth),
AvgLgth)[1] then
	Value2 = 2.1 * Average(RSI(Price, RSILgth), AvgLgth)
else
	Value2 = 0;

	Value3 = RSI(Price, RSILgth) + Summation(Value1, RSILgth) +
Summation(Value2, RSILgth);
	
{The 15 unit triple smoothed Part3}

RSIDerivOsc = Average(Average(Average(Value3, RSIDerivOscLgth),
RSIDerivOscLgth), RSIDerivOscLgth);

Plot1(RSIDerivOsc,"RSIDerivOsc");

========================================================================
=


Thomas

Thomas J. Festa, CMT
Technical Analysis Trading Systems Developer
Senior Proprietary Trader - Equities
Hold Brothers, LLC
230 Headquarters Plaza
East Tower, 2nd Floor
Morristown, NJ  07960
Cell:   (908) 581-8880

Confidentiality Notice: The information contained in this e-mail and any
attachments may be legally privileged and confidential. If you are not
an intended recipient, you are hereby notified that any dissemination,
distribution, or copying of this e-mail is strictly prohibited. If you
have received this e-mail in error, please notify the sender and
permanently delete the e-mail and any attachments immediately. You
should not retain, copy or use this e-mail or any attachment for any
purpose, nor disclose all or any part of the contents to any other
person.