PureBytes Links
Trading Reference Links
|
Hello mguess,
Sunday, December 23, 2001, 3:52:06 PM, you wrote:
m> Does anyone have the code for the TSI (Trend Strength Indicator, I
m> believe) described in the current issue of Active Trader?
m> Thnx,
m> Michael
Here you go.
{true strength index by Blau}
Inputs:Price(close),rlength(25),slength(13);
var:TSI(0);
value1 = close - close[1];
value2 = xaverage(xaverage(value1, rlength), slength);
value3 = xaverage(xaverage(absvalue(value1), rlength), slength);
if value3 > 0 then TSI = 100*value2/value3 else TSI = 0;
var: TSIAvg(0);
TSIAvg = xaverage(tsi,7);
plot1(tsi,"TSI",blue);
plot2(TSIAvg,"tsiavg",red);
plot3(25,"oversold",yellow );
plot4(-25,"overbought", cyan);
--
Best regards,
Ernie mailto:ebonugli@xxxxxxxx
|