Hi,
I try to screen for stocks who move less than x% each day.
I tried the following:
CL = Close
CL1 = Close [1]
Perc1 = CL/CL1*100-100 //(I also tried CL1/CL)
Con1 = Perc1 <= 3
SCREENER[Con1]
I still get stocks that moved 4% for example,
Thx for the help 🙂
Try this (not tested):
CL = Close
CL1 = Close[1]
Perc1 = (((max(CL,CL1)/(min(CL,CL1))*100)-100
Con1 = Perc1 <= 3
SCREENER[Con1]
Please re-read the forum rules before posting again and always use the ‘Insert PRT Code’ button when posting code. I will edit and tidy up your post.
Hi,
First of all, thank you very much.
I tried but I keep getting an error on this line:
Perc1 = (((max(CL,CL1)/(min(CL,CL1))*100)-100
“Syntx error: line 3, character 43
Please complete the syntax of this line.”
Thx alot.
Hi,
Fixed it, was missing a )) at the end.
Thank you very much.
Sorry – unequal amount of ()
Change it to:
Perc1 = ((max(CL,CL1)/min(CL,CL1))*100) -100
I think my head has been out in the Greek sun too much! This is the calculation you should be using:
Perc1 = ((abs(close-open)/open)*100)
Perc1 = ((abs(close-open)/open)*100)
Doesn’t work.
Shouldn’t I compare the closing of the last two candles?
If you want to include any gaps then just change OPEN to CLOSE[1]