Type/to search

Quant Trend Following Strategy

Common strategy
Created: 2024-01-04 15:25:42
Last modified: 3 years ago
1
Follow
1802
Followers

img

Overview

The Quant Trend Following Strategy is a trend tracking strategy based on EMA lines and ATR stop loss. It uses EMA lines to judge the overall market trend direction, and dynamically tracks stop loss with ATR to lock in trend profits, maximizing returns.

Principles

The strategy consists of the following main parts:

  1. EMA lines to determine primary trend

    Use 13-day, 50-day and 100-day lines to form bullish/bearish bias and judge primary trend direction.

  2. ATR dynamic stop loss

    Use ATR indicator to calculate price movement range of current period and set stop loss price to lock in profits.

  3. Signal smoothing

    Smooth closing prices over a certain period with SMA to avoid false signals.

  4. Bullish/bearish signals

    Go long when price crosses over EMA lines, go short when crosses below. Set dynamic ATR trailing stop loss.

Advantage Analysis

The strategy has the following advantages:

  1. Excellent drawdown control, max drawdown within 160%.
  2. Dynamic stop loss smarter than fixed one, can lock in more trend profits.
  3. Using EMA to determine primary trend avoids reversal trades.
  4. Smoothed bars filter fake signals and improve win rate.

Risk Analysis

There are also some risks:

  1. Static parameters may not fit different products, optimization needed.
  2. Stop loss may gap out in ranging markets.
  3. Requires server stability to avoid missing signals.

These risks can be reduced via parameter optimization, adaptability testing etc.

Optimization Directions

The strategy can be optimized in the following aspects:

  1. Automated parameter optimization with machine learning algorithms.
  2. Add adaptive stop loss based on market conditions.
  3. Increase compound filters to improve stability.
  4. Consider cross product testing to improve adaptability.

Conclusions

In summary, this is a quant strategy designed based on trend following concept. It determines trend direction with EMA and uses dynamic ATR stop loss. It can effectively control drawdown while capturing trend profits. Continued optimization and iteration can generate improved results.

Source
Pine
/*backtest
start: 2023-12-27 00:00:00
end: 2024-01-03 00:00:00
period: 10m
basePeriod: 1m
exchanges: [{"eid":"Futures_Binance","currency":"BTC_USDT"}]
*/

//@version=4
strategy("Combined Strategy", overlay=true)

// Input variables for EMA Crossover
Strategy parameters
Strategy parameters
EMA 13 Length
EMA 50 Length
EMA 100 Length
EMA 200 Length
Signal Smoothing
Simple MA (Signal Line)
Lin Reg
Linear Regression Length
Key Value. 'This changes the sensitivity'
ATR Period
Signals from Heikin Ashi Candles
Comment
All comments (0)
No data
No data
  • 1
Forums
PINE Language
Get the app
iPhone Download
© 2015 - ∞ INVENTOR PTE LTD (SG)