OPEN-SOURCE SCRIPT

Relative Strength (Volatility Adjusted)

已更新
The volatility adjusted relative strength indicator offers a more precise approach to traditional RS indicators by incorporating volatility adjustments into its calculations. This will provide traders with a more nuanced view of relative performance between a selected instrument and a comparison index.

Identifying Relative Strength (RS) and Weakness (RW) against a benchmark like the SPY is crucial for traders, as it highlights institutional activity in an equity, which retail traders rarely achieve on their own. However, the traditional method of simply comparing the rate of change of a stock to the rate of change for the SPY can be flawed. This method often fails to account for the inherent volatility of each stock, leading to misleading RS/RW readings.

Consider two stocks that both move in response to SPY's movements. If SPY moves significantly more than its average (measured by its ATR), and the stock does the same, traditional RS calculations might show strength when, in fact, the stock is just mirroring SPY's increased volatility. For instance, if SPY typically moves $0.25 an hour but suddenly moves $1, and a stock typically moves $0.50 but moves $2, the stock's apparent RS might be overstated, when in reality there is no relative strength for the stock.

By adjusting for volatility using the ATR (Average True Range), we normalize these movements and get a clearer picture of true RS/RW. For example, if SPY moves 5 times its average rate and a stock moves the same multiple of its own ATR, the RS should be considered neutral rather than strong. Similarly if a stock in absolute terms moves $1 while the SPY also moves $1 but the stock usually moves at twice the rate of the SPY, the stock should be considered relatively weak - not neutral.

Usage
Use this to identify stocks with actual strength or weakness compared to the market.

  • When the RS line is above 0 and above the moving average it indicates a stock with relative strength that is still gaining more strength.
  • When the RS line is above 0 but above the moving average it indicates a stock with relative strength that is currently losing strength.
  • When the RS line is below 0 and below the moving average it indicates a stock with relative weakness that is still losing strength.
  • When the RS line is below 0 but above the moving average it indicates a stock with relative weakness that is starting to gain back some strength.

發布通知
The volatility adjusted relative strength indicator offers a more precise approach to traditional RS indicators by incorporating volatility adjustments into its calculations. This will provide traders with a more nuanced view of relative performance between a selected instrument and a comparison index.

Identifying Relative Strength (RS) and Weakness (RW) against a benchmark like the SPY is crucial for traders, as it highlights institutional activity in an equity, which retail traders rarely achieve on their own. However, the traditional method of simply comparing the rate of change of a stock to the rate of change for the SPY can be flawed. This method often fails to account for the inherent volatility of each stock, leading to misleading RS/RW readings.

Consider two stocks that both move in response to SPY's movements. If SPY moves significantly more than its average (measured by its ATR), and the stock does the same, traditional RS calculations might show strength when, in fact, the stock is just mirroring SPY's increased volatility. For instance, if SPY typically moves $0.25 an hour but suddenly moves $1, and a stock typically moves $0.50 but moves $2, the stock's apparent RS might be overstated, when in reality there is no relative strength for the stock.

By adjusting for volatility using the ATR (Average True Range), we normalize these movements and get a clearer picture of true RS/RW. For example, if SPY moves 5 times its average rate and a stock moves the same multiple of its own ATR, the RS should be considered neutral rather than strong. Similarly if a stock in absolute terms moves $1 while the SPY also moves $1 but the stock usually moves at twice the rate of the SPY, the stock should be considered relatively weak - not neutral.

Usage
Use this to identify stocks with actual strength or weakness compared to the market.

  1. When the RS line is above 0 and above the moving average it indicates a stock with relative strength that is still gaining more strength.
  2. When the RS line is above 0 but below the moving average it indicates a stock with relative strength that is currently losing strength.
  3. When the RS line is below 0 and below the moving average it indicates a stock with relative weakness that is still losing strength.
  4. When the RS line is below 0 but above the moving average it indicates a stock with relative weakness that is starting to gain back some strength.
發布通知
  • Made indicator more customizable with ability to change MA type, MA length and ATR length.
  • Fixed bug with moving average dynamic coloring
marketrelativestrengthRelative Strength ComparisonRSSPDR S&P 500 ETF (SPY) StocksstrengthTrend Analysis

開源腳本

在真正的TradingView精神中,這個腳本的作者以開源的方式發佈,這樣交易員可以理解和驗證它。請向作者致敬!您可以免費使用它,但在出版物中再次使用這段程式碼將受到網站規則的約束。 您可以收藏它以在圖表上使用。

想在圖表上使用此腳本?

免責聲明