OPEN-SOURCE SCRIPT

Relative Strength vs SPX


This indicator calculates the ratio of the current chart's price to the S&P 500 Index (SPX), providing a measure of the stock's relative strength compared to the broader market.

Key Features:

Dynamic High/Low Detection: Highlights periods when the ratio makes a new high (green) or a new low (red) based on a user-defined lookback period.
Customizable Lookback: The lookback period for detecting highs and lows can be adjusted in the settings for tailored analysis.
Visual Overlay: The ratio is plotted in a separate pane, allowing easy comparison of relative strength trends.
This tool is useful for identifying stocks outperforming or underperforming the S&P 500 over specific timeframes.
relativeRelative Strength ComparisonstrengthtrendTrend Analysis

开源脚本

本着真正的TradingView精神,此脚本的作者已将其开源,以便交易者可以理解和验证它。向作者致敬!您可以免费使用它,但在出版物中重复使用此代码受网站规则约束。 您可以收藏它以在图表上使用。

想在图表上使用此脚本?

免责声明