Triple Moving Average Combined with MACD Quantitative Strategy
Overview
This strategy develops a relatively stable and reliable quantitative trading strategy by combining the use of triple moving average indicator and MACD indicator. It aims to capture possible future trends and is particularly suitable for medium and long term holdings.
Strategy Principle
The strategy is mainly based on the combination of triple moving average and MACD indicator.
Firstly, the strategy uses triple exponential moving averages with lengths of 3, 7 and 2 respectively. These three moving averages construct a fast to slow moving average system to determine the direction of future trends. When the short-term moving average crosses over the longer-term moving average, it is a long signal; when the short-term moving average crosses below the longer-term moving average, it is a short signal.
Secondly, the strategy also uses MACD indicator with parameters of 3 and 7 simultaneously. When MACD main line crosses over signal line, it is long signal, and when it crosses below, it is short signal.
By combining the use of dual indicators, it can avoid multiple false signals caused by a single indicator, thereby improving the stability of the strategy.
Advantages of the Strategy
- Improved signal quality by using dual indicator filtering
- Parameters have been tested and optimized many times, stable and reliable
- The triple moving average system can effectively filter market noise and determine future trends
- MACD indicator parameters are set faster to quickly capture short term opportunities
Risks of the Strategy
- There are certain risks of drawdown and consecutive losses
- When the market has no obvious trend, there will be more false trades in this strategy
- MACD indicator is prone to generating false signals and needs to be combined with moving average indicators
Solutions:
- Adopt appropriate stop loss strategy to control maximum drawdown
- Reduce trading frequency when market state is clearly trendless
- Optimize MACD parameters and use in combination with other indicators
Directions for Strategy Optimization
- Test and optimize parameters of moving averages and MACD to find the best combination
- Increase auxiliary indicators like KDJ and VRSI to avoid false signals
- Introduce machine learning models to judge market state and achieve dynamic adjustment
- Combine with stop loss strategies and set optimal stop loss points
Summary
This strategy achieves stable trend capturing through the combination of moving averages and MACD. Its advantage lies in the combination use of indicators, which can effectively reduce false signals and obtain better strategy performance. Next steps to further improve the strategy include introducing parameters optimization, stop loss strategies, dynamic adjustment etc, making it an effective tool to find medium and long term opportunities.
/*backtest
start: 2023-01-10 00:00:00
end: 2024-01-16 00:00:00
period: 1d
basePeriod: 1h
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/
//@version=3
strategy("Matt's MACD Algo v1", shorttitle="Matt's MACD Algo v1", overlay=true, pyramiding = 0, default_qty_type = strategy.percent_of_equity, default_qty_value = 100, initial_capital=7000, calc_on_order_fills = true, commission_type=strategy.commission.percent, commission_value=0, currency = currency.USD)
//study("MFI Fresh", shorttitle="MFI Fresh", overlay=true)
- 1

