SI
SI
discoversearch

We've detected that you're using an ad content blocking browser plug-in or feature. Ads provide a critical source of revenue to the continued operation of Silicon Investor.  We ask that you disable ad blocking while on Silicon Investor in the best interests of our community.  If you are not using an ad blocker but are still receiving this message, make sure your browser's tracking protection is set to the 'standard' level.
Strategies & Market Trends : MDA - Market Direction Analysis -- Ignore unavailable to you. Want to Upgrade?


To: Matthew L. Jones who wrote (26117)9/16/1999 6:31:00 PM
From: Haim R. Branisteanu  Read Replies (1) | Respond to of 99985
 
Matt this is the program generating Stoch, RSI, Breakout signals

{ SCRIPT : SCAN1.TAS Screen for various conditions and create a report with BUY/SELL Signals
x day price breakout
y day volume breakout
Stochastics buy/sell RSI breakout }
#MAX_QUOTES 100
#OUTPUT_FILE 'SCAN1.LST N'

PRICE_BREAKOUT_PERIOD = 50; { Price breakout lookback period}
VOL_BREAKOUT_PERIOD = 30; { Volume breakout lookback period}
STOCH_PERIOD = 14; { Stoch %K period}
STOCH_SLOW = 3; { Stoch %D slowing}
RSI_PERIOD = 14; { RSI period}
VOL_PERCENT = 300; { Percentage for VOLUME BREAKOUT}
{ Declare various arrays to hold the results of indicators }
HHV_A : ARRAY; { Place to save HHV}
VOL_A : ARRAY; { Place to save Volume Moving average}
STK_A : ARRAY; { Place to save Stochastic %K}
STD_A : ARRAY; { Place to save Stochastic %D}
RSI_A : ARRAY; { Place to save RSI }
HHV_A = HHV(C,PRICE_BREAKOUT_PERIOD);
VOL_A = MOV(V,VOL_BREAKOUT_PERIOD,'S');
{ Use STOCH_PERIOD day stoch with 3 day slowing}
STK_A = STOCH(STOCH_PERIOD,3);
{ Compute %D as 3 day EMA of %K}
STD_A = MOV(STK_A,STOCH_SLOW,'E');
{ RSI_PERIOD Day RSI}
RSI_A = RSI(RSI_PERIOD);
PRICE_BREAKOUT = 0;
VOL_BREAKOUT = 0;
STOCH_BUY = 0;
STOCH_SELL = 0;
RSI_BUY = 0;
RSI_SELL = 0;
if CLOSE OF TODAY IS GREATER THAN HHV_A OF YESTERDAY THEN
begin
PRICE_BREAKOUT = 1;
end;
if VOLUME OF TODAY IS GREATER THAN
VOL_PERCENT/100 * VOL_A OF YESTERDAY THEN
begin
VOL_BREAKOUT = (VOLUME OF TODAY/VOL_A OF YESTERDAY) * 100;
end;
if STD_A OF YESTERDAY IS LESS THAN OR EQUAL TO 20 AND
STK_A OF YESTERDAY IS LESS THAN STD_A OF YESTERDAY AND
STK_A OF TODAY IS GREATER THAN STD_A OF TODAY THEN
begin
STOCH_BUY = 1;
end;
if STD_A OF YESTERDAY IS GREATER THAN OR EQUAL TO 80 AND
STK_A OF YESTERDAY IS GREATER THAN STD_A OF YESTERDAY AND
STK_A OF TODAY IS LESS THAN STD_A OF TODAY THEN
begin
STOCH_SELL = 1;
end;
if RSI_A of YESTERDAY IS LESS THAN OR EQUAL TO 30 AND
RSI_A OF TODAY IS GREATER THAN 30 THEN
begin
RSI_BUY = 1;
end;
if RSI_A of YESTERDAY IS GREATER THAN 70 and RSI_A of TODAY
IS LESS THAN 70 THEN
begin
RSI_SELL = 1;
end;
IF FIRST_TICKER THEN
begin
WRITELN(
' CURR PREV CURR STOCH '
);
WRITELN(
'TICKER NAME CLOSE CLOSE Vol % %K %D RSI'
);
WRITELN(
'------------------------ ------- ------- ------- ------- ------- -------'
);
end;
IF PRICE_BREAKOUT OR VOL_BREAKOUT OR STOCH_BUY OR STOCH_SELL OR
RSI_BUY OR RSI_SELL THEN
BEGIN
WRITELN(ticker,fullname,close, close of yesterday,
((volume/VOL_A[-1]))*100,'%%',stk_a,std_a,
RSI_A);
IF PRICE_BREAKOUT THEN
WRITELN('\t\t* PRICE BREAKOUT ABOVE ',
INT(PRICE_BREAKOUT_PERIOD), ' DAY HIGH OF CLOSE');
IF VOL_BREAKOUT THEN
WRITELN('\t\t* VOLUME BREAKOUT ',VOL_BREAKOUT,
' PERCENT OVER LAST',
INT(VOL_BREAKOUT_PERIOD), ' DAYS');
IF STOCH_BUY THEN
WRITELN('\t\t* STOCH BUY');
IF STOCH_SELL THEN
WRITELN('\t\t* STOCH SELL');
IF RSI_BUY THEN
WRITELN('\t\t* RSI BUY');
IF RSI_SELL THEN
WRITELN('\t\t* RSI SELL');
END;



To: Matthew L. Jones who wrote (26117)9/16/1999 7:41:00 PM
From: HairBall  Respond to of 99985
 
Matt: The only one on this thread I know that divided his signals into classes is donald sew. You need to get him to explain them.

Regards,
LG