The ClucHAnix strategy is a trading strategy that utilizes various indicators to determine buy and sell signals. Here is a brief description of what the strategy does:
In the populate_indicators method:
It calculates Heikin-Ashi candles based on the input dataframe. It calculates Bollinger Bands using the typical price of the Heikin-Ashi candles.
It calculates the absolute differences between the middle Bollinger Band and the lower Bollinger Band, the closing prices of consecutive candles, and the closing prices and the lowest prices of the Heikin-Ashi candles.
It assigns the calculated values to different columns in the dataframe.
It calculates the exponential moving averages (EMA) of the Heikin-Ashi closing prices with different time periods. It calculates the rolling mean of the volume over a 30-candle window. It calculates the Rate of Change Ratio (ROCR) based on the Heikin-Ashi closing prices. In the populate_buy_trend method:
It retrieves the parameters for buying from self.buy_params. It applies a set of conditions to determine when to place a buy signal:
The ROCR of the Heikin-Ashi candles in the 1-hour timeframe is greater than a specified threshold. Several conditions related to Bollinger Bands, including the lower Bollinger Band, its delta, the delta of closing prices, and the tail of the candles. The current Heikin-Ashi closing price is lower than the previous lower Bollinger Band and lower than the previous Heikin-Ashi closing price. In the populate_sell_trend method:
It retrieves the parameters for selling from self.sell_params. It applies a set of conditions to determine when to place a sell signal:
The Fisher Transform indicator is greater than a specified threshold. Conditions related to the Heikin-Ashi high prices, closing prices, exponential moving averages, and Bollinger Bands. The strategy combines these indicators and conditions to generate buy and sell signals in the given dataframe.