Skip to content

RS ratio and Momentum calculations

Benny Thadikaran edited this page Oct 31, 2024 · 3 revisions

Knowing how the formula works, helps to understand and interpret the values on the RRG charts.

I used ChatGPT and this article on Z-score to understand the formula.

The formula itself was picked from An0n1mity/RRGPy.

1. Relative Strength (RS) ratio

Relative strength measures the stock's performance in comparison to a benchmark index like NIFTY 50.

A rising RS indicates the stock is outperforming the Index and and a declining RS shows under performance.

The Relative strength of a stock is determined by dividing the stock price with the benchmark index.

$$ rs = \left( \frac{\text{stock price}}{\text{benchmark price}} \right) \times 100 $$

Multiplying the result by 100, gives a percentage measure.

2. Standardization of RS (Z-Score)

$$ \text{RS Ratio} = \frac{\text{RS} - \text{SMA}(\text{RS}, 14)}{\text{Standard Deviation of RS}} + 100 $$

The first part, subtracts the RS from it moving average. This measures how the RS performs against its average. A positive value indicates the RS is above average and vice versa.

The second part, divides the resulting value with the standard deviation of RS.

The result is a multiple of the Std.Dev. (How many standard deviations is the RS from its average.). Values can be above or below 0.

The final step adds 100 to serve as a baseline. All values are now above or below 100.

2. RS Momentum

$$ \text{Rate Of Change (ROC)} = \left( \frac{\text{RS ratio}}{\text{RS ratio}_{t-1}} - 1 \right) \times 100 $$

The first part, divides RS ratio by its value from a previous period. This compares the current RS to its old value.

  • A positive value indicates an increase and vice versa.
  • An unchanged RS ratio will result in 1. We correct this in the next step.

The second part, reduces 1 and normalizes the values. If the RS ratio is unchanged, the result in 1. Reducing 1 makes it 0. All values are now centered around 0.

The final part, converts the result into a percentage change relative to the old value.

To calculate the momentum value, we apply the same earlier Z-score standardization formula.

$$ \text{RS Momentum} = \frac{\text{ROC} - \text{SMA}(\text{ROC}, 14)}{\text{Std Dev of ROC}} + 100 $$

Summary

To summarize, both the RS ratio and RS momentum are multiples of Standard deviation.

Clone this wiki locally