InvestorsHub Logo

Quasi

03/08/10 8:29 PM

#6535 RE: Sexton O Blake #6534

Re; Sexton O Blake, Scan for "close" near SMA50…

Yes, great question and it can be done easily in the advanced scan engine, with a couple of math functions as follows.

Note the first couple of lines are what I use to limit the output when developing scans, I don't want more than a few charts to check for results. The last two lines are what you need to be within the +/- 50 cent range of the SMA 50.

[type = stock]
and [Close > 25] and [Close < 26]
and [SMA(50,close) * SMA(50,volume) > 500000]
and [close >= sma(50,close)-0.50]
and [close <= sma(50,close)+0.50]

(Note you can't use the + or - function in the basic scan engine)

However I rarely use hard offsets as I prefer percentages, 50 cents on a five dollar stock is a lot, but 50 cents on Google is peanuts. Try using percentages and it takes the stock price variable out of the equation. The following is basically the same but just looking for the close to be within +/- 2% of the SMA 50.

[type = stock]
and [Close > 25] and [Close < 26]
and [SMA(50,close) * SMA(50,volume) > 500000]
and [close >= sma(50,close)*0.98]
and [close <= sma(50,close)*1.02]

(Note the * function is available in the basic and advanced scan engine)

That should give you some ideas and point you in the right direction. I won't write all your requested scenarios for you, but I think you have the info now.

Good luck, let us know if you need more help.

Quasi