Tesis
SuperTrend regime gates three layered Fib pullback entries — long, short, mirrored.
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.
Calm during chop because no regime is established; bursts of activity when a clean trend prints and price wicks into the Fib zone. Pullback re-entries cluster around the trail line, so the equity curve looks like staircase steps inside each trend leg.
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.
_template:
title: Blackflag FTS — SuperTrend + Fib pullback ladder
category: trend_following
skill: intermediate
name: blackflag_fts
weight: 1.0
long_only: false
indicators:
bf:
kind: blackflag_fts
atr_period: 28
atr_factor: 5
trail_type: modified
fib1: 0.618
fib2: 0.786
fib3: 0.886
c:
kind: sma
period: 1
entry:
combine: OR
rules:
- combine: AND
direction: long
rules:
- {lhs: {indicator: bf, field: state}, op: eq, rhs: {value: 1}}
- {lhs: {indicator: c}, op: crosses_down, rhs: {indicator: bf, field: fib1}}
- combine: AND
direction: long
rules:
- {lhs: {indicator: bf, field: state}, op: eq, rhs: {value: 1}}
- {lhs: {indicator: c}, op: crosses_down, rhs: {indicator: bf, field: fib2}}
- combine: AND
direction: long
rules:
- {lhs: {indicator: bf, field: state}, op: eq, rhs: {value: 1}}
- {lhs: {indicator: c}, op: crosses_down, rhs: {indicator: bf, field: fib3}}
- combine: AND
direction: short
rules:
- {lhs: {indicator: bf, field: state}, op: eq, rhs: {value: -1}}
- {lhs: {indicator: c}, op: crosses_up, rhs: {indicator: bf, field: fib1}}
- combine: AND
direction: short
rules:
- {lhs: {indicator: bf, field: state}, op: eq, rhs: {value: -1}}
- {lhs: {indicator: c}, op: crosses_up, rhs: {indicator: bf, field: fib2}}
- combine: AND
direction: short
rules:
- {lhs: {indicator: bf, field: state}, op: eq, rhs: {value: -1}}
- {lhs: {indicator: c}, op: crosses_up, rhs: {indicator: bf, field: fib3}}
exit:
combine: OR
rules:
- {lhs: {indicator: bf, field: state}, op: crosses_down, rhs: {value: 0}}
- {lhs: {indicator: bf, field: state}, op: crosses_up, rhs: {value: 0}}
risk:
trailing_stop_pct: 0.04
cooldown_bars: 2
Indicadores
bfBlackflag FTS (ATR 28, factor 5)Port of Jose Azcarate's Pine v4 Blackflag FTS indicator: a Wilder ATR-band SuperTrend that tracks the trend extreme and projects three Fib pullback levels (61.8 / 78.6 / 88.6 %) inside the active regime.
cSMA(1) close wrapperOne-bar SMA over close so the rule evaluator's crosses_* operators see a real previous value. Without this, bar-level closes collapse prev = now and crossing predicates never fire.
Condiciones de entrada
El bot abre una posición en la vela siguiente al cumplimiento de todas las condiciones de abajo.
- Long-side ladder: close crosses down through any of the three Fib levels while Blackflag state = +1 (uptrend).
- Short-side ladder mirrors above the Fib levels while state = -1.
- First trigger wins; the trailing stop handles re-entry cadence.
Condiciones de salida
Cualquiera de las condiciones siguientes cierra la posición.
- SuperTrend regime flips through zero in either direction — the framework routes the matching exit to the active position.
- 4% trailing stop locks in the run; 2-bar cooldown after exit.
Comportamiento esperado
Calm during chop because no regime is established; bursts of activity when a clean trend prints and price wicks into the Fib zone. Pullback re-entries cluster around the trail line, so the equity curve looks like staircase steps inside each trend leg.
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.