OPEN-SOURCE SCRIPT

IT-Dual Relative Strength

Updated
One can use this indicator to compare two security i.e. (Nifty and stock with its own sector) how it is performing in compare with preferred index ( Nifty 50 by default).
> 0 outperforming
< 0 underperforming

Works best for Daily TF, but can be applied to Weekly and monthly charts .
Can be use on smaller time frame as well, as per the number of hour you want to calculate.
Apply it to Nifty 50 , industry index, sector index or other security in similar sector

I have Added the Box table as well which shows the performance agents Nifty and selected sector.
Release Notes
This is the upgraded version for IT-Dual Relative Strength with same name but V2.0

One can use this indicator to compare two security i.e. ( Nifty and stock with its own sector) how it is performing in compare with preferred index ( Nifty 50 by default).
> 0 outperforming
< 0 underperforming

Works best for Daily TF, but can be applied to Weekly and monthly charts .
Can be use on smaller time frame as well, as per the number of hour you want to calculate.
Apply it to Nifty 50 , industry index, sector index or other security in similar sector

I have Added the Box table as well which shows the performance agents Nifty and selected sector.

Release Notes:
Added toggle color option on crossovers
Fixed bug on label display, even when plot option was disabled
Release Notes
In addition to the existing RS behavior, it is now possible to superimpose price-action behavior on the RS line.
As per existing RS, RS above zero indicates outperformance/strength over the selected benchmark and RS below zero indicates underperformance/weakness over the selected benchmark for the selected period.

Added length of SMA/EMA for RS is 9
dualRelative Strength Comparison

Open-source script

In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in publication is governed by House rules. You can favorite it to use it on a chart.

Want to use this script on a chart?

Disclaimer