OPEN-SOURCE SCRIPT

ROCkin RSI

Atualizado
ROCkin RSI Indicator
Overview
The "ROCkin RSI" indicator combines the traditional Relative Strength Index (RSI) with an innovative approach using the Rate of Change (ROC) to offer a new way to visualize and interpret market momentum. By averaging the slope of the RSI over time and allowing for different types of moving averages, this indicator aims to help traders identify trending and reversal patterns more efficiently.
Features
RSI Calculations: The core of the indicator is based on the standard Relative Strength Index, an oscillator that measures the speed and change of price movements. The RSI oscillates between 0 and 100 and is usually used to identify overbought or oversold conditions.
Rate of Change of Price (ROC): Instead of simply plotting the RSI, this indicator calculates the Rate of Change of the closing price, essentially looking at how steep the RSI curve is over a user-defined period.
Smoothing: To reduce noise and make the curve smoother, the slope of the RSI is averaged over a given number of periods, which can either be a Simple Moving Average (SMA) or an Exponential Moving Average (EMA).
Column Plots: The smoothed RSI slope is plotted as columns, where the color of the columns (red or green) indicates whether the slope is positive or negative.
Optional RSI Moving Average: The indicator also offers an optional feature to plot a moving average of the smoothed RSI slope, aiding in trend identification.
Inputs
RSI Periods: The number of periods used to calculate the RSI.
Slope Periods: The number of periods used for calculating the Rate of Change.
Average Periods: The number of periods used for smoothing the RSI slope.
Type of Average: Choose between EMA (Exponential Moving Average) and SMA (Simple Moving Average) for smoothing.
Show RSI Moving Average: Toggle this to either show or hide the moving average of the smoothed RSI slope.
Moving Average Period: The period used for calculating the RSI Moving Average.
Moving Average Type: Choose between EMA and SMA for the RSI Moving Average.
How to Interpret
Positive Slope (Red Columns): Indicates upward momentum in the RSI, which may imply a bullish trend.
Negative Slope (Green Columns): Indicates downward momentum in the RSI, suggesting a possible bearish trend.
RSI Moving Average: Acts as a signal line to confirm the trend. When the smoothed RSI slope is above its moving average, it confirms the bullish trend, and when it's below, it confirms the bearish trend.
Practical Use
Entry/Exit Signals: Consider entering a long position when the columns of the green histogram cross above the moving average. Conversely, consider entering a short position when the columns cross under when red. The higher the columns the more likely the trade will be a good one.

Fine-Tuning and Optimization
It's crucial to understand that the default settings might not be optimal for all trading scenarios. The effectiveness of the ROCkin RSI indicator can vary based on the asset you're trading, the market conditions, and your trading style. Therefore, it's highly recommended to play with the settings and study the historical performance on the chart to grasp how the indicator behaves.

By experimenting with different periods for RSI, the Rate of Change, and the moving averages, you can tailor the indicator to better suit your needs. Studying how the indicator would have performed in the past can help you understand its potential strengths and weaknesses. Once you've got a feel for how it operates, you can then optimize the settings to align with your trading strategy and risk tolerance.





Notas de Lançamento
* Update to change colors

ROCkin RSI Indicator
Overview
The "ROCkin RSI" indicator combines the traditional Relative Strength Index (RSI) with an innovative approach using the Rate of Change (ROC) to offer a new way to visualize and interpret market momentum. By averaging the slope of the RSI over time and allowing for different types of moving averages, this indicator aims to help traders identify trending and reversal patterns more efficiently.
Features
RSI Calculations: The core of the indicator is based on the standard Relative Strength Index, an oscillator that measures the speed and change of price movements. The RSI oscillates between 0 and 100 and is usually used to identify overbought or oversold conditions.
Rate of Change of Price (ROC): Instead of simply plotting the RSI, this indicator calculates the Rate of Change of the closing price, essentially looking at how steep the RSI curve is over a user-defined period.
Smoothing: To reduce noise and make the curve smoother, the slope of the RSI is averaged over a given number of periods, which can either be a Simple Moving Average (SMA) or an Exponential Moving Average (EMA).
Column Plots: The smoothed RSI slope is plotted as columns, where the color of the columns (red or green) indicates whether the slope is positive or negative.
Optional RSI Moving Average: The indicator also offers an optional feature to plot a moving average of the smoothed RSI slope, aiding in trend identification.
Inputs
RSI Periods: The number of periods used to calculate the RSI.
Slope Periods: The number of periods used for calculating the Rate of Change.
Average Periods: The number of periods used for smoothing the RSI slope.
Type of Average: Choose between EMA (Exponential Moving Average) and SMA (Simple Moving Average) for smoothing.
Show RSI Moving Average: Toggle this to either show or hide the moving average of the smoothed RSI slope.
Moving Average Period: The period used for calculating the RSI Moving Average.
Moving Average Type: Choose between EMA and SMA for the RSI Moving Average.
How to Interpret
Positive Slope (Red Columns): Indicates upward momentum in the RSI, which may imply a bullish trend.
Negative Slope (Green Columns): Indicates downward momentum in the RSI, suggesting a possible bearish trend.
RSI Moving Average: Acts as a signal line to confirm the trend. When the smoothed RSI slope is above its moving average, it confirms the bullish trend, and when it's below, it confirms the bearish trend.
Practical Use
Entry/Exit Signals: Consider entering a long position when the columns of the red histogram cross above the moving average. Conversely, consider entering a short position when the columns cross under when green. The higher the columns the more likely the trade will be a good one.

Fine-Tuning and Optimization
It's crucial to understand that the default settings might not be optimal for all trading scenarios. The effectiveness of the ROCkin RSI indicator can vary based on the asset you're trading, the market conditions, and your trading style. Therefore, it's highly recommended to play with the settings and study the historical performance on the chart to grasp how the indicator behaves.

By experimenting with different periods for RSI, the Rate of Change, and the moving averages, you can tailor the indicator to better suit your needs. Studying how the indicator would have performed in the past can help you understand its potential strengths and weaknesses. Once you've got a feel for how it operates, you can then optimize the settings to align with your trading strategy and risk tolerance.

Notas de Lançamento
Overview
The "ROCkin RSI" indicator combines the traditional Relative Strength Index (RSI) with an innovative approach using the Rate of Change (ROC) to offer a new way to visualize and interpret market momentum. By averaging the slope of the RSI over time and allowing for different types of moving averages, this indicator aims to help traders identify trending and reversal patterns more efficiently.
Features
RSI Calculations: The core of the indicator is based on the standard Relative Strength Index, an oscillator that measures the speed and change of price movements. The RSI oscillates between 0 and 100 and is usually used to identify overbought or oversold conditions.
Rate of Change of Price (ROC): Instead of simply plotting the RSI, this indicator calculates the Rate of Change of the closing price, essentially looking at how steep the RSI curve is over a user-defined period.
Smoothing: To reduce noise and make the curve smoother, the slope of the RSI is averaged over a given number of periods, which can either be a Simple Moving Average (SMA) or an Exponential Moving Average (EMA).
Column Plots: The smoothed RSI slope is plotted as columns, where the color of the columns (red or green) indicates whether the slope is positive or negative.
Optional RSI Moving Average: The indicator also offers an optional feature to plot a moving average of the smoothed RSI slope, aiding in trend identification.
Inputs
RSI Periods: The number of periods used to calculate the RSI.
Slope Periods: The number of periods used for calculating the Rate of Change.
Average Periods: The number of periods used for smoothing the RSI slope.
Type of Average: Choose between EMA (Exponential Moving Average) and SMA (Simple Moving Average) for smoothing.
Show RSI Moving Average: Toggle this to either show or hide the moving average of the smoothed RSI slope.
Moving Average Period: The period used for calculating the RSI Moving Average.
Moving Average Type: Choose between EMA and SMA for the RSI Moving Average.
How to Interpret
Positive Slope (Red Columns): Indicates upward momentum in the RSI, which may imply a bullish trend.
Negative Slope (Green Columns): Indicates downward momentum in the RSI, suggesting a possible bearish trend.
RSI Moving Average: Acts as a signal line to confirm the trend. When the smoothed RSI slope is above its moving average, it confirms the bullish trend, and when it's below, it confirms the bearish trend.
Practical Use
Entry/Exit Signals: Consider entering a long position when the columns of the green histogram cross above the moving average. Conversely, consider entering a short position when the columns cross under when red. The higher the columns the more likely the trade will be a good one.

Fine-Tuning and Optimization
It's crucial to understand that the default settings might not be optimal for all trading scenarios. The effectiveness of the ROCkin RSI indicator can vary based on the asset you're trading, the market conditions, and your trading style. Therefore, it's highly recommended to play with the settings and study the historical performance on the chart to grasp how the indicator behaves.

By experimenting with different periods for RSI, the Rate of Change, and the moving averages, you can tailor the indicator to better suit your needs. Studying how the indicator would have performed in the past can help you understand its potential strengths and weaknesses. Once you've got a feel for how it operates, you can then optimize the settings to align with your trading strategy and risk tolerance.

* Updated settings menu to be more descriptive
* Updated calculations (RSI length wasn't previously affecting the calculation)
Notas de Lançamento
UPDATE: Complete rewrite of the code. Condensed for readability, with comments. New and improved description. Changed default settings. Corrected some calculation errors.

Overview:
The "ROCkin RSI" is a custom-built trading indicator designed to offer enhanced insight into market trends. This indicator combines elements of the Relative Strength Index (RSI) and Rate of Change (ROC) while also allowing for smoothing and a unique moving average overlay on the RSI value or its slope. The output is visualized through a colored histogram and an optional moving average line that changes color based on RSI levels (zones), both offering valuable perspectives on market conditions.

Key Components:
RSI: The Relative Strength Index is used to identify the momentum of a price trend over a certain length of time, as well as overbought or oversold conditions.

RSI ROC: Rate of Change applied to the RSI. It quantifies how quickly RSI is changing over a specified period.

Smoothing: A smoothed version of the RSI ROC is calculated to reduce noise and better identify prevailing trends.

RSI MA: This feature offers an optional moving average overlay that can be applied to either the RSI value or the RSI Slope (explained below). The color of this moving average changes based on pre-defined RSI zones, making it easier to gauge the momentum at a glance. This can allow traders to replace the standard RSI indicator with this more informative version that combines trend information with general RSI levels.

Here's how the moving average colors are set based on RSI levels:
When the RSI value is between 0 and 25, the color is light pink.
When the RSI value is between 25 and 45, the color is red.
When the RSI value is between 45 and 55, the color is yellow.
When the RSI value is between 55 and 75, the color is lime green.
When the RSI value is 75 or higher, the color is light green.

** These colors provide a visual indicator of the RSI level and can help in understanding the momentum as indicated by the RSI. The colors make it easier to see if the RSI is at a level where it typically might be considered to have strong upward momentum (lime green), strong downward momentum (red), or if it's more neutral (yellow). These are also commonly referred to as overbought and oversold conditions at the two extremes, which can help keep you from taking a trade that may turn around shortly after.

RSI Slope: The RSI Slope is essentially the difference between the current RSI value and its average over the ROC length, normalized by dividing by the ROC length. This measures how quickly the RSI is changing relative to its average value over a given period, providing a sense of the momentum or speed of the change in RSI.

Keep in mind that the RSI slope can be positive, negative, or zero:
- A positive slope indicates that the current RSI is greater than its average over the ROC length, suggesting increasing momentum.
- A negative slope indicates that the current RSI is less than its average over the ROC length, suggesting decreasing momentum.
- A zero slope would mean that the current RSI is equal to its average over the ROC length, indicating no change in momentum.

Settings:

**NOTE: Smaller values will allow for shorter trades while longer values will allow for holding through more volatility.

RSI Length: Affects the length of the RSI calculation. A shorter length will make the RSI more sensitive to price changes.

RSI Calculation MA Type: Allows you to choose the moving average type for the RSI calculation. Different MA types will alter the sensitivity and reaction time of the RSI.

RSI Rate of Change Length: Determines the length of the ROC applied to the RSI, affecting how responsive the indicator is to changes in RSI.

Smoothing Length: Adjusts how much the RSI ROC is smoothed. Higher values will result in smoother but less responsive lines. This is good for watching trends slowly grow and fade out, but will limit your ability to use it for entry and exit signals in a fast moving market.

RSI MA Length and Type: Settings for the optional RSI MA overlay. The length will affect how closely the MA follows the RSI, and the type will affect its sensitivity.

Use RSI or RSI Slope for MA?: Allows you to choose whether the MA is applied to the RSI value itself or its slope.

Potential Uses:

Trend Identification: The color of the histogram can indicate the market trend. A green histogram can be a bullish signal, while a red histogram can be bearish.

Overbought/Oversold: The RSI MA colors can be useful for identifying overbought or oversold conditions and changes in momentum.

Crossovers: Pay attention to when the RSI MA line crosses the histogram or vice versa, as it could be indicative of a changing trend.

Divergence: Watch how the histogram and moving average highs and lows from one to the next compare to the price, if the two are not in agreement, this can give you an indication of an incoming change of direction and a change in the trend of the price.
Notas de Lançamento
Update:
Wrong code was updated unexpectedly.

Overview:
The "ROCkin RSI" is a custom-built trading indicator designed to offer enhanced insight into market trends. This indicator combines elements of the Relative Strength Index (RSI) and Rate of Change (ROC) while also allowing for smoothing and a unique moving average overlay on the RSI value or its slope. The output is visualized through a colored histogram and an optional moving average line that changes color based on RSI levels (zones), both offering valuable perspectives on market conditions.
Key Components:
RSI: The Relative Strength Index is used to identify the momentum of a price trend over a certain length of time, as well as overbought or oversold conditions.


RSI ROC: Rate of Change applied to the RSI. It quantifies how quickly RSI is changing over a specified period.


Smoothing: A smoothed version of the RSI ROC is calculated to reduce noise and better identify prevailing trends.


RSI MA: This feature offers an optional moving average overlay that can be applied to either the RSI value or the RSI Slope (explained below). The color of this moving average changes based on pre-defined RSI zones, making it easier to gauge the momentum at a glance. This can allow traders to replace the standard RSI indicator with this more informative version that combines trend information with general RSI levels.

Here's how the moving average colors are set based on RSI levels:
When the RSI value is between 0 and 25, the color is light pink.
When the RSI value is between 25 and 45, the color is red.
When the RSI value is between 45 and 55, the color is yellow.
When the RSI value is between 55 and 75, the color is lime green.
When the RSI value is 75 or higher, the color is light green.

These colors provide a visual indicator of the RSI level and can help in understanding the momentum as indicated by the RSI. The colors make it easier to see if the RSI is at a level where it typically might be considered to have strong upward momentum (lime green), strong downward momentum (red), or if it's more neutral (yellow). These are also commonly referred to as overbought and oversold conditions at the two extremes, which can help keep you from taking a trade that may turn around shortly after.


RSI Slope: The RSI Slope is essentially the difference between the current RSI value and its average over the ROC length, normalized by dividing by the ROC length. This measures how quickly the RSI is changing relative to its average value over a given period, providing a sense of the momentum or speed of the change in RSI.


Keep in mind that the RSI slope can be positive, negative, or zero:
A positive slope indicates that the current RSI is greater than its average over the ROC length, suggesting increasing momentum.
A negative slope indicates that the current RSI is less than its average over the ROC length, suggesting decreasing momentum.
A zero slope would mean that the current RSI is equal to its average over the ROC length, indicating no change in momentum.


Settings:
NOTE: Smaller values will allow for shorter trades while longer values will allow for holding through more volatility.

RSI Length: Affects the length of the RSI calculation. A shorter length will make the RSI more sensitive to price changes.

RSI Calculation MA Type: Allows you to choose the moving average type for the RSI calculation. Different MA types will alter the sensitivity and reaction time of the RSI.

RSI Rate of Change Length: Determines the length of the ROC applied to the RSI, affecting how responsive the indicator is to changes in RSI.

Smoothing Length: Adjusts how much the RSI ROC is smoothed. Higher values will result in smoother but less responsive lines. This is good for watching trends slowly grow and fade out, but will limit your ability to use it for entry and exit signals in a fast moving market.

RSI MA Length and Type: Settings for the optional RSI MA overlay. The length will affect how closely the MA follows the RSI, and the type will affect its sensitivity.

Use RSI or RSI Slope for MA?: Allows you to choose whether the MA is applied to the RSI value itself or its slope.

Potential Uses:
Trend Identification: The color of the histogram can indicate the market trend. A green histogram can be a bullish signal, while a red histogram can be bearish.


Overbought/Oversold: The RSI MA colors can be useful for identifying overbought or oversold conditions and changes in momentum.


Crossovers: Pay attention to when the RSI MA line crosses the histogram or vice versa, as it could be indicative of a changing trend.


Divergence: Watch how the histogram and moving average highs and lows from one to the next compare to the price, if the two are not in agreement, this can give you an indication of an incoming change of direction and a change in the trend of the price.

Moving AveragesOscillatorsTrend Analysis

Script de código aberto

No verdadeiro espírito do TradingView, o autor desse script o publicou como código aberto, para que os traders possam compreendê-lo e analisá-lo. Parabéns ao autor! Você pode usá-lo gratuitamente, mas a reutilização desse código em publicações é regida pelas Regras da Casa. Você pode favoritá-lo para usá-lo em um gráfico.

Quer usar esse script no gráfico?


Também em:

Aviso legal