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 : TA-Quotes Plus -- Ignore unavailable to you. Want to Upgrade?


To: Sean W. Smith who wrote (6892)9/29/1998 2:00:00 PM
From: Bob Jagow  Respond to of 11149
 
Need to reread the msgs for context, Sean.
See also my #6880.
-------------------------------
maxHi:= max(0, numdays, cl);
minLo:= min(0, numdays, cl);
for i=numdays to 0 step 1 do // reverse for speed
if close(i) >= maxHi then
maxHi := close(i);
maxDate := i;
i := 0;
endif;
next i;
for i=numdays to 0 step 1 do
if close(i) <= minLo then
minLo := close(i);
minDate := i;
i := 0;
endif;
next i;
----------------------
Should double the speed on average; reversing the 1st scan order
would add speed if one believes that stocks usually go up.
-Bob



To: Sean W. Smith who wrote (6892)10/1/1998 2:06:00 PM
From: TechTrader42  Read Replies (1) | Respond to of 11149
 
Sean: Is this the final version of your Hi Lo scan? (Thsnks for the scan, btw.)

// Hi Lo by Sean Smith

exchange = nyse, amex, nasdaq;
output = "hilo.lst";

// input="vol250.lst";
// ProcessMS = "f:\invest\metadata\hilo\",VMS;

daystoload = 2200;
daysrequired =1;

Integer numdays,i,maxHi, minLo, minDate, maxDate;

numdays:=((DaysLoaded-1)*-1);

minLo := 99999999;
maxHi := 0;
maxDate := 0;
minDate := 0;

for i=numdays to 0 step 1 do

if close(i) >= maxHi then
maxHi := close(i);
maxDate := i;
endif;

if close(i) <= minLo then
minLo := close(i);
minDate := i;
endif;

next i;

Print Symbol:-5,",","cl:0",",",close(0):6:2,",",
"Max",",",close(maxDate),",MaxDate,",Date(maxDate);
PrintLn "Min",",",close(MinDate),",MinDate,",Date(MinDate);