Noon Barbari
Registrati

Torna alla libreria di strategie

Trend followingLong e short4h1d

Multi-period trend confluence strategy

Fast and slow trend regimes must agree before opening — long or short.

Tesi

Fast and slow trend regimes must agree before opening — long or short.

Si adatta ai setup Trend following — funziona meglio quando il comportamento del mercato sottostante combacia con la tesi, e si rompe quando no. Abbinala alla modalità walk-forward del backtester prima di impegnare capitale reale.

Trend follower with patience. Long flat periods when the two timeframes disagree, then steady runs when the slow regime turns and the fast one confirms. Drawdowns are deeper because exits wait for chop, not a clean flip.

Set di regole YAML

Incollalo nella scheda «Text» del Strategy Designer, oppure usa il pulsante della dashboard sopra per caricarlo come template.

name: multi_trend_confluence
weight: 1.0
long_only: false
indicators:
  trend20:  {kind: trend, period: 20,  slope_lookback: 3}
  trend100: {kind: trend, period: 100, slope_lookback: 8}
entry:
  combine: OR
  rules:
    - combine: AND
      direction: long
      rules:
        - {lhs: {indicator: trend20},  op: eq, rhs: {value: 1}}
        - {lhs: {indicator: trend100}, op: eq, rhs: {value: 1}}
    - combine: AND
      direction: short
      rules:
        - {lhs: {indicator: trend20},  op: eq, rhs: {value: -1}}
        - {lhs: {indicator: trend100}, op: eq, rhs: {value: -1}}
exit:
  combine: OR
  rules:
    - {lhs: {indicator: trend100}, op: eq, rhs: {value: 0}}
risk:
  trailing_stop_pct: 0.07
  cooldown_bars: 8

Indicatori

  • trend20Trend regime (period 20, slope 3)

    Categorical regime indicator: +1 when price is above EMA(20) AND the EMA is rising over the last 3 bars, -1 in the mirror down-regime, 0 in chop.

  • trend100Trend regime (period 100, slope 8)

    Same indicator on a much slower window — captures the broad market regime. Acts as the bigger-picture filter.

Condizioni d'ingresso

Il bot apre una posizione nella candela successiva al verificarsi di tutte le condizioni qui sotto.

  • Long when BOTH trend20 = +1 AND trend100 = +1.
  • Short when BOTH trend20 = -1 AND trend100 = -1.
  • 8-bar cooldown after exit.

Condizioni di uscita

Una qualsiasi delle condizioni qui sotto chiude la posizione.

  • Exit immediately when the slower trend100 regime flips to 0 (chop).
  • 7% trailing stop on the runner.

Comportamento atteso

Trend follower with patience. Long flat periods when the two timeframes disagree, then steady runs when the slow regime turns and the fast one confirms. Drawdowns are deeper because exits wait for chop, not a clean flip.

Carattere della curva di equity, non una previsione di rendimento. I backtest non sono promesse sulla performance live.

Provala con i tuoi dati

Apri il template nella dashboard per fare backtest su BTC, ETH o qualsiasi simbolo CCXT — oppure copia il YAML nel Strategy Designer per modificarlo prima.

Il comportamento passato nei backtest non garantisce la performance futura. I mercati cambiano; i set di regole vanno rivalidati. Si fa trading a proprio rischio.