Biên tập viên chọnOPEN-SOURCE SCRIPT

Industry Group Strength

Cập nhật
The Industry Group Strength indicator is designed to help traders identify the best-performing stocks within specific industry groups. The movement of individual stocks is often closely tied to the overall performance of their industry. By focusing on industry groups, this indicator allows you to find the top-performing stocks within an industry.

Thanks to a recent Pine Script update, an indicator like this is now possible. Special thanks to PineCoders for introducing the dynamic requests feature.

How this indicator works:
The indicator contains predefined lists of stocks for each industry group. To be included in these lists, stocks must meet the following basic filters:

  • Market capitalization over 2B
  • Price greater than $10
  • Primary listing status


Once the relevant stocks are filtered, the indicator automatically recognizes the industry group of the current stock displayed on the chart. It then retrieves and displays data for that entire industry group.

Data Points Available:
The user can choose between three different data points to rank and compare stocks:

  • YTD (Year-To-Date) Return: Measures how much a stock has gained or lost since the start of the year.
  • RS Rating: A relative strength rating for a user-selected lookback period (explained below).
  • % Return: The percentage return over a user-selected lookback period.


Stock Ranking:
Stocks are ranked based on their performance within their respective industry groups, allowing users to easily identify which stocks are leading or lagging behind others in the same sector.

Visualization:
The indicator presents stocks in a table format, with performance metrics displayed both as text labels and color-coded lines. The color gradient represents the percentile rank, making it visually clear which stocks are outperforming or underperforming within their industry group.

Relative Strength (RS):
Relative Strength (RS) measures a stock’s performance relative to a benchmark, typically the S&P 500 (the default setting). It is calculated by dividing the closing price of the stock by the closing price of the S&P 500.

If the stock rises while the S&P 500 falls, or if the stock rises more sharply than the S&P 500, the RS value increases. Conversely, if the stock falls while the S&P 500 rises, the RS value decreases. This indicator normalizes the RS value into a range from 1 to 99, allowing for easier comparison across different stocks, regardless of their raw performance. This normalized RS value helps traders quickly assess how a stock is performing relative to others.

Phát hành các Ghi chú
update to label count
Phát hành các Ghi chú
Added data label next to industry group name. Fixed typo.
Breadth IndicatorsPortfolio managementTrend Analysis

Mã nguồn mở

Theo tinh thần TradingView thực sự, tác giả của tập lệnh này đã xuất bản dưới dạng nguồn mở để các nhà giao dịch có thể hiểu và xác minh. Chúc mừng tác giả! Bạn có thể sử dụng miễn phí. Tuy nhiên, bạn cần sử dụng lại mã này theo Quy tắc nội bộ. Bạn có thể yêu thích nó để sử dụng nó trên biểu đồ.

Bạn muốn sử dụng tập lệnh này trên biểu đồ?


Trusted Pine programmer. Send me a message for script development.
Ngoài ra, trên:

Thông báo miễn trừ trách nhiệm