Im trying to create a scan to identify stocks that have two sequential closes above a 10D SMA of the high
in other words, i want to find stocks who closed above a 10D SMA of the highs for two days in a row
I can get part of the way but have a hard time figuring out how to get the two days in a row part.
what i have so far is below - trying to accomplish the two days in a row part by altering the "within" parameter but it doesnt work well
can anyone help?
basically using this as a part of a moving average channel strategy(MAC) - two closes above the MAC = buy signal
close is greater than SimpleMovingAvg("price" = HIGH, "length" = 10)."SMA" and close is greater than SimpleMovingAvg("price" = HIGH, "length" = 10)."SMA" within 2 bars and close crosses above SimpleMovingAvg("price" = HIGH, "length" = 10)."SMA" within 3 bars
in other words, i want to find stocks who closed above a 10D SMA of the highs for two days in a row
I can get part of the way but have a hard time figuring out how to get the two days in a row part.
what i have so far is below - trying to accomplish the two days in a row part by altering the "within" parameter but it doesnt work well
can anyone help?
basically using this as a part of a moving average channel strategy(MAC) - two closes above the MAC = buy signal
close is greater than SimpleMovingAvg("price" = HIGH, "length" = 10)."SMA" and close is greater than SimpleMovingAvg("price" = HIGH, "length" = 10)."SMA" within 2 bars and close crosses above SimpleMovingAvg("price" = HIGH, "length" = 10)."SMA" within 3 bars