The MultiMa Strategy V2 is a trading strategy designed for backtesting. It uses multiple moving averages (MA) to generate buy and sell signals. The strategy calculates various parameters based on user-defined inputs.
The strategy has two sets of parameters: buy_params and sell_params.
The buy_params determine the conditions for buying, while the sell_params determine the conditions for selling.
For buying, the strategy uses the buy_ma_count and buy_ma_gap parameters. It checks if the current MA value is lower than the previous MA value for each specified count and gap. If all the conditions are met, a buy signal is generated. For selling, the strategy uses the sell_ma_count and sell_ma_gap parameters. It checks if the current MA value is higher than the previous MA value for each specified count and gap. If any of the conditions are met, a sell signal is generated. The strategy also includes a minimal_roi parameter, which defines the desired return on investment (ROI) at different stages of the trade. Additionally, it has a stoploss parameter that specifies the maximum acceptable loss before triggering a stoploss. The timeframe parameter defines the desired timeframe for the strategy. The strategy calculates and populates various indicators, such as TEMA (Triple Exponential Moving Average), based on the provided dataframe and metadata. Overall, the MultiMa Strategy V2 aims to generate buy and sell signals based on the specified moving average conditions, allowing for backtesting and evaluation of its performance.