The E0V1E strategy is a trading strategy that uses various indicators to generate entry and exit signals for long positions. Here's a breakdown of what the strategy does:
Indicator Population: The strategy starts by populating several indicators on the input dataframe. These indicators include:
Simple Moving Average (SMA) with a time period of 15.
Cumulative Total Indicator (CTI) with a length of 20, calculated using the closing prices.
Relative Strength Index (RSI) with time periods of 14, 4, and 20.
Stochastic Fast %K and %D with parameters (5, 3, 0, 3, 0). Exponential Moving Averages (EMA) with time periods of 100 and 200. Bollinger Bands with a window of 20 and 2 standard deviations. Bollinger Bands' width, calculated as the difference between the upper and lower bands divided by the middle band. Rolling mean of volume with windows of 12 and 24. Williams %R with a period of 14. Entry Signal Generation: After populating the indicators, the strategy defines conditions for generating entry signals for long positions. The conditions include:
RSI slow crossing below its previous value. RSI fast below a specified threshold (self.buy_rsi_fast_32.value). RSI above a specified threshold (self.buy_rsi_32.value). Close price below the 15-day SMA multiplied by a specified factor (self.buy_sma15_32.value). CTI below a specified threshold (self.buy_cti_32.value). EMA 100 below EMA 200 multiplied by a specified factor (self.buy_r_deadfish_ema.value). Bollinger Bands' width above a specified threshold (self.buy_r_deadfish_bb_width.value). Close price below the Bollinger Bands' middle band multiplied by a specified factor (self.buy_r_deadfish_bb_factor.value). Volume mean 12 above volume mean 24 multiplied by a specified factor (self.buy_r_deadfish_volume_factor.value). CTI below a specified threshold (self.buy_r_deadfish_cti.value). Williams %R below a specified threshold (self.buy_r_deadfish_r14.value). The strategy appends these conditions to a list and updates the 'enter_tag' column of the dataframe to indicate the respective conditions that are met. Exit Signal Generation: Similarly, the strategy defines conditions for generating exit signals for long positions. The condition is:
Fast %K crossing above a specified threshold (self.sell_fastx.value). The strategy appends this condition to a list and updates the 'exit_tag' column of the dataframe to indicate the condition that is met. Signal Assignment: If any conditions for entering or exiting a trade are met, the strategy updates the 'enter_long' or 'exit_long' column of the dataframe, respectively, to mark the respective signals. The strategy utilizes a combination of technical indicators to identify potential entry and exit points for long positions.