The V-RSI Trading Strategy: A Comprehensive Overview
Written on
Chapter 1: Introduction to the V-RSI Strategy
This article delves into a fascinating discretionary approach to the Relative Strength Index (RSI), which hinges on validating normality.
I have recently published a book titled "Contrarian Trading Strategies in Python," which encompasses numerous advanced contrarian indicators and methodologies. A dedicated GitHub page supports the book with continuously updated code. If you are interested, you can purchase the PDF version for 9.99 EUR via PayPal. Please ensure you include your email in the payment note so you receive the document correctly. After receiving it, remember to download it from Google Drive.
Chapter 2: Understanding the Relative Strength Index
The Relative Strength Index (RSI) is undoubtedly the most recognized momentum indicator available, largely due to its many advantages, particularly in fluctuating markets. It ranges from 0 to 100, which simplifies its interpretation. Its popularity also enhances its effectiveness; as more traders and portfolio managers utilize the RSI, market reactions to its signals increase, potentially influencing price movements. This concept aligns with the self-fulfilling nature of technical analysis, even if it cannot be empirically proven.
To compute the RSI, we begin by calculating the price differences for each period. This involves subtracting each closing price from the one preceding it. We then determine the smoothed average of positive and negative differences. This provides the Relative Strength, which is integrated into the RSI formula, transforming it into a value between 0 and 100.
To calculate the RSI, we require an Open-High-Low-Close (OHLC) array (not a DataFrame). This means we will examine an array comprising four columns.
# The function to add a number of columns inside an array
def adder(Data, times):
for i in range(1, times + 1):
new_col = np.zeros((len(Data), 1), dtype=float)
Data = np.append(Data, new_col, axis=1)
return Data
# The function to delete a number of columns starting from an index
def deleter(Data, index, times):
for i in range(1, times + 1):
Data = np.delete(Data, index, axis=1)return Data
# The function to delete a number of rows from the beginning
def jump(Data, jump):
Data = Data[jump:, ]
return Data
For instance, to add three empty columns to an array, we would call my_ohlc_array = adder(my_ohlc_array, 3).
Next, we could delete two columns after the one indexed at 3 using my_ohlc_array = deleter(my_ohlc_array, 3, 2) and remove the first 20 rows with my_ohlc_array = jump(my_ohlc_array, 20).
Chapter 3: Implementing the V Strategy
The V strategy is predicated on a rapid response from the RSI when it identifies support or resistance levels. Signals are generated following the completion of a V formation. The trading rules are as follows:
- A Buy signal occurs whenever the 13-period RSI forms a V pattern, where the current value exceeds 30, the previous value is below 30, and the one before that is above 30. These readings must be consecutive.
- A Sell signal is indicated when the 13-period RSI forms an inverted V, where the current value is below 70, the previous value exceeds 70, and the one before that is below 70. These readings must also be consecutive.
def signal(data, close_price, rsi_column, buy, sell):
data = adder(data, 5)
for i in range(len(data)):
if data[i, rsi_column] > 30 and data[i - 1, rsi_column] < 30 and data[i - 2, rsi_column] > 30:
data[i, buy] = 1elif data[i, rsi_column] < 70 and data[i - 1, rsi_column] > 70 and data[i - 2, rsi_column] < 70:
data[i, sell] = -1return data
The first video titled "RSI Trading Strategy Relative Strength Index" provides an in-depth look at the RSI and its application in trading, making it a valuable resource for understanding this strategy.
Chapter 4: Conclusion and Recommendations
To summarize, my goal is to enhance the domain of objective technical analysis by advocating for more transparent techniques and strategies that should be rigorously back-tested before deployment. This approach aims to dispel the negative perception of technical analysis as being subjective and lacking scientific backing.
Medium serves as a platform for engaging reads. Prior to writing, I consumed a plethora of articles. I encourage you to consider joining Medium via my referral link at no extra cost to you.
Here are essential steps to follow when encountering a trading technique or strategy:
- Maintain a critical mindset and eliminate emotional bias.
- Back-test using realistic simulations and conditions.
- If potential is identified, optimize and conduct forward testing.
- Always factor in transaction costs and slippage in your assessments.
- Incorporate risk management and position sizing into your analysis.
Lastly, even after thorough testing, remain vigilant and monitor the strategy, as market dynamics can evolve and render the strategy ineffective.
The second video titled "The ONLY RSI Trading Strategy That PERFECTLY Times Market Reversals..." explores a unique approach to utilizing the RSI for effective market timing, providing further insights into this trading strategy.