New Members: Be sure to confirm your email address by clicking on the link that was sent to your email inbox. You will not be able to post messages until you click that link.
Scan for Relative Strength slope
hi, I want to scan for a raising Relative Strength (price of the stock divided by the $SPX price) over X number of days.
So I was thinking of using the slope function with something like this:
Slope(3, close/close($spx)) > 0
But I cannot make this work, I appreciate any guidance on how to determine the slope of this
0
Comments
there is the price relative function in the candle glance list view, is there a way to call this variable out in the scan engine?
https://support.stockcharts.com/doku.php?id=scans:functions
So, you could write
[group is SP500]
and [PctRelative(20,$spx) > 0]
rank by PctRelative(20,$spx)
and you would get a list of sp 500 stocks that are outperforming the index, in order by the per cent outperformance over the last 20 days.
To get a positive slope, you might be able to put PctRelative inside sma( ), e.g.
and [sma(20, PctRelative(20,$spx)) > 10 days ago sma(20, PctRelative(20,$spx))]
I haven't tried it. If it works, you might be able to test the results against Price Relative indicator with parameters $symbol:$spx . I'm not sure if the calculation is the same, but the PR line should be in the same direction, I think.