MACD Momentum Indicator Backtest Strategy
Overview
This strategy combines the MACD momentum indicator with the RSI overbought/oversold indicator. When MACD crosses up or down, it checks if RSI also completes the corresponding bottoming/topping reversal over the lookback period to generate more reliable trading signals. Typical short-term mean reversion strategy logic.
Strategy Logic
-
Calculate MACD DIFF, DEA and histogram. Crossover of DIFF above DEA gives bullish crossover signal, and crossover below gives death cross signal.
-
Calculate RSI to identify oversold bounces and overbought selloffs. Lookback window checks if recent bottoming or topping has occurred.
-
When MACD bullish crossover happens, if RSI has bounced off oversold within lookback window, long signal is generated. On MACD death cross, short signal is generated if RSI topped over lookback window.
-
Stop loss set after entry to control risk.
Advantages
-
MACD sensitively identifies trend changes. RSI effectively judges overbought/oversold levels.
-
Requiring both MACD and RSI signals filters out false signals.
-
Lookback window improves signal reliability.
-
Stop loss aids risk management.
Risks
-
Lagging of MACD and RSI may cause missed optimal entries.
-
Lower probability of dual-indicator signal means fewer trades.
-
No consideration of larger trend direction risks being trapped.
-
Poor stop loss tuning may be too wide or too tight.
Possible Solutions:
-
Adjust MACD and RSI parameters to reduce lag.
-
Widen indicator threshold ranges to provide more signals.
-
Add trend filter to avoid counter-trend entries.
-
Test different stop loss parameters for optimal levels.
Optimization Directions
-
Test SMA and other moving averages.
-
Add trailing stop loss for flexible stops.
-
Incorporate trend strength to judge entry quality.
-
Use machine learning to predict indicator movements.
-
Combine more factors to optimize entry timing.
Summary
This strategy filters for reliable reversal signals using coordinated MACD and RSI. The logic is clear and parameters flexible for enhancements like indicator selection, trend filters, stop loss techniques etc to acquire more trades while maintaining stability, but over-optimization risks need to be avoided.
- 1
