Please help me detect MA200 sloping up

Hello experts,

I've been looking through the forum for a way to scan for stocks where the 200MA has been sloping up for the past 20 days, but no luck so far. I tried Fxshrat’s approach, but the moving average still looks too flat. Does anyone know a better way to find stocks with a steeper 200MA slope?
(Detect when moving averages are about to cross - #8 by fxshrat)
Thanks a lot for the support and Happy New Year!

What about below simple approach?

MA200=ma(c,200);
slope=MA200-ref(MA200,-1);
buy=slope>0;

Thanks a lot.
I've already tested this method, but what I really need is a strong, sharp upward slope for the MA200 during the most recent 20 days.

Ok here is some suggestion in mind,

MA200=ma(c,200);
slope=MA200-ref(MA200,-1);
buy1=iif(slope>0,1,iif(slope<=0,-1,0));
buy=sum(buy1,20)>threshold;
 

Another one would be

slope=(ma200-ref(ma200,-10))/10; //10 bars back adjustable 
buy=slope>threshold;  //threshold is between 0.01 to 0.5 
1 Like

You could look for the rate of change of the MA:

pctThreshold = 5;     // Try different threshold values
ma200 = MA(C,200);
rocMA = ROC(ma200, 20);
isMaMovingUp = rocMA > pctThreshold;
1 Like

The MA200 is not sensitive enough to detect any sudden change in price. It's like a tsunami in the open sea. A good example is the MA200 on DJI when the tariffs war was declared in April 2005.

3 Likes