Noon Barbari
Registrarse

Volver a la biblioteca de estrategias

Seguimiento de tendenciaLargos y cortos4h1d

Multi-period trend confluence strategy

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

Tesis

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

Encaja con los setups de Seguimiento de tendencia — funciona mejor cuando el comportamiento del mercado coincide con la tesis, y falla cuando no. Combínala con el modo walk-forward del backtester antes de comprometer capital real.

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.

Conjunto de reglas YAML

Pégalo en la pestaña «Text» del Strategy Designer, o usa el botón del panel de arriba para cargarlo como plantilla.

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

Indicadores

  • 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.

Condiciones de entrada

El bot abre una posición en la vela siguiente al cumplimiento de todas las condiciones de abajo.

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

Condiciones de salida

Cualquiera de las condiciones siguientes cierra la posición.

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

Comportamiento esperado

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.

Es el carácter de la curva de equity, no una previsión de retorno. Los backtests no son promesas sobre el desempeño en vivo.

Pruébala con tus datos

Abre la plantilla en el panel para hacer backtest sobre BTC, ETH o cualquier símbolo CCXT — o copia el YAML en el Strategy Designer para editarlo primero.

El comportamiento pasado en backtests no garantiza el desempeño futuro. Los mercados cambian; los conjuntos de reglas necesitan revalidarse. Operas bajo tu propio riesgo.