News Focus
News Focus
Followers 12
Posts 1003
Boards Moderated 1
Alias Born 10/29/2006

Re: Peter_Pan post# 6655

Monday, 09/06/2010 3:38:20 PM

Monday, September 06, 2010 3:38:20 PM

Post# of 7257
RE: Peter scan for EMA50 within 2%...

Yes it can be done using the advanced scan engine, similar application is covered in an article I wrote for the scanning blog back in March.

http://blogs.stockcharts.com/scanning/2010/03/sc.html

In your particular case the coding would be modified. Basically you find the EMA 50 value for today, multiply by 1.02 & 0.98 to get the plus / minus 2%. Then set the values of the EMA 50 for the past ten days to be within that range, ie max for 10 days is less than the +2% (1.02)and min for 10 days to be greater than the -2% (0.98).

[type = stock]
and [max (10, EMA(50, close) ) <= EMA(50, close) * 1.02]
and [min (10, EMA(50, close) ) >= EMA(50, close) * 0.98]

hope this gives you some ideas
Quasi

I don't work for Stockcharts, I'm just another user always trying to learn more and willing to share what I've already learned.
Stockcharts.com Support Forum

Discover What Traders Are Watching

Explore small cap ideas before they hit the headlines.

Join Today