OPEN-SOURCE SCRIPT
RS Rating Multi-Timeframe v2

RS Rating Multi-Timeframe
A relative strength rating indicator modeled after IBD's proprietary RS Rating system. This indicator measures a stock's price performance relative to the S&P 500 (or any benchmark you choose) and converts it to a 1-99 rating scale.
How It Works
The indicator calculates weighted performance ratios across four timeframes:
40% weight: 63-day (3-month) performance
20% weight: 126-day (6-month) performance
20% weight: 189-day (9-month) performance
20% weight: 252-day (12-month) performance
This weighting emphasizes recent performance while still accounting for longer-term strength—the same methodology used by leading growth stock research services.
Rating Scale
90-99: Elite relative strength (top 10% of stocks)
80-89: Strong relative strength (top 20%)
50-79: Average performance
30-49: Below average
1-29: Weak relative strength (bottom 30%)
Features
Customizable benchmark index (default: S&P 500)
Optional moving average overlay (EMA or SMA)
Visual zones with color-coded backgrounds
Signal markers when RS crosses key thresholds (80 and 30)
Info table showing current rating, daily change, MA value, and raw score
Built-in alerts for threshold crossovers
Pine Screener Compatible
This indicator includes state-based plots specifically designed for TradingView's Pine Screener. You can screen watchlists for:
RS Above 90, 80, 70, or 50
RS Below 50 or 30
RS Above/Below its moving average
Custom thresholds using the raw RS Rating value
In the Pine Screener, select the "Screener RS Above 80" output and set it to "True" (or equals 1) to find all stocks currently above 80—not just those crossing on that bar.
Usage Tips
Growth investors typically look for stocks with RS Ratings above 80, indicating the stock is outperforming 80% of the market. Combining high RS Rating with other technical signals (breakouts, volume, moving averages) can help identify leading stocks.
A relative strength rating indicator modeled after IBD's proprietary RS Rating system. This indicator measures a stock's price performance relative to the S&P 500 (or any benchmark you choose) and converts it to a 1-99 rating scale.
How It Works
The indicator calculates weighted performance ratios across four timeframes:
40% weight: 63-day (3-month) performance
20% weight: 126-day (6-month) performance
20% weight: 189-day (9-month) performance
20% weight: 252-day (12-month) performance
This weighting emphasizes recent performance while still accounting for longer-term strength—the same methodology used by leading growth stock research services.
Rating Scale
90-99: Elite relative strength (top 10% of stocks)
80-89: Strong relative strength (top 20%)
50-79: Average performance
30-49: Below average
1-29: Weak relative strength (bottom 30%)
Features
Customizable benchmark index (default: S&P 500)
Optional moving average overlay (EMA or SMA)
Visual zones with color-coded backgrounds
Signal markers when RS crosses key thresholds (80 and 30)
Info table showing current rating, daily change, MA value, and raw score
Built-in alerts for threshold crossovers
Pine Screener Compatible
This indicator includes state-based plots specifically designed for TradingView's Pine Screener. You can screen watchlists for:
RS Above 90, 80, 70, or 50
RS Below 50 or 30
RS Above/Below its moving average
Custom thresholds using the raw RS Rating value
In the Pine Screener, select the "Screener RS Above 80" output and set it to "True" (or equals 1) to find all stocks currently above 80—not just those crossing on that bar.
Usage Tips
Growth investors typically look for stocks with RS Ratings above 80, indicating the stock is outperforming 80% of the market. Combining high RS Rating with other technical signals (breakouts, volume, moving averages) can help identify leading stocks.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.