Skip to content

View translation

EthBtcRelativeStrengthMomentumPairLS

Hypotheses

ETH-vs-BTC Relative-Strength Momentum, Dollar-Neutral Long-Short Pair (BINANCE USD-M Perps, DAILY Bars — Long the Stronger Major / Short the Weaker Based on the Sign of the ~30-Day Relative Return, Deadband to Suppress Whipsaw, Trend-Flip Exit, 3-Parameter)

Hypotheses

A MARKET-NEUTRAL (dollar-neutral) relative-momentum pairs strategy on the two deepest-liquidity crypto majors: ETHUSDT.BINANCE (primary) and BTCUSDT.BINANCE (secondary), both USD-M perpetuals, DAILY bars. The single signal is the RELATIVE trend of the two names: r = (ETH's N-day log return) minus (BTC's N-day log return), N ~= 30 days. When r rises above a positive deadband, ETH is winning the relative race, so go LONG ETHUSDT and SHORT BTCUSDT in equal dollar notional (dollar-neutral, ~zero net crypto-beta). When r falls below the negative deadband, flip to SHORT ETHUSDT / LONG BTCUSDT. Inside the deadband the book is flat. Both legs are sized to the same notional so the position is a pure bet on the ETH/BTC RATIO trend, not on the direction of crypto overall. This is intentionally NOT a single-name directional momentum clone (L91), NOT a diversified vol-targeted TSMOM basket (L77), NOT a cross-sectional rank rotation across many names (L68), NOT a cointegration mean-reversion pair (that fades the spread; this RIDES the spread trend), and NOT a beta-amplified single-name trade. It is relative-strength CONTINUATION — the surviving slow-trend/momentum family expressed as a two-leg, market-neutral spread on the only two contracts deep enough that market impact and capacity (the killers of the Bybit-ETH TSMOM and ATOM-confluence books) are non-issues. 3 parameters only (lookback N, deadband width, ATR trailing-stop multiple on the spread) to keep overfitting risk low.

Hypotheses

Implements the hypothesis exactly: relative-strength continuation, not mean reversion (the spread trend is RIDDEN, never faded), on the two deepest crypto contracts so capacity/impact are non-issues. The decision variable is returned in natural units every bar (a relative return, typically +-0.30) and thresholded in should_enter against the matching-unit deadband; should_exit owns the trend-flip and ATR-trailing exits. Dollar-neutrality is structural (L59): the hedge notional is taken from the ETH fill's actual qty x avg_px_open, both legs carry the same USD notional, and the per-bar reconcile closes any orphaned hedge, so the book never carries net crypto beta that could liquidate. Sizing is capital-relative and bounded (per_leg_notional_frac x leverage x equity = 0.5x equity per leg -> 1.0x gross), independent of the signal magnitude, so losses cannot compound into position size (L15). leverage=2.0 is genuinely consumed in position_size(): a two-leg book with 1.0x gross needs 100% of equity as initial margin at 1x, which leaves no headroom for fees/PnL and risks order rejection; at 2x the same gross uses ~0.5x equity of margin. Futures venue is required because the strategy is short one leg at all times. Entry frequency: on daily bars a 30-day ETH-vs-BTC relative return has ~10% dispersion, so |r| > 2% fires frequently (tens of round trips over the sandbox/backtest window), avoiding the zero-trade failure mode; warmup is only 32 daily bars. Per-trade edge: holds run for weeks of ratio trend against ~0.20% four-leg round-trip taker cost.

Hypotheses

analyzing_stuck_3_timeouts

Implementation

Dollar-neutral ETH-vs-BTC relative-strength CONTINUATION pair on Binance USD-M perps, daily bars. Signal r = log(ETH/BTC)_t - log(ETH/BTC)_{t-N} (== ETH N-day log return minus BTC N-day log return, N~30), computed every bar from a timestamp-synced two-leg buffer. r above +deadband -> LONG ETHUSDT + SHORT BTCUSDT in equal USD notional; r below -deadband -> SHORT ETHUSDT + LONG BTCUSDT; inside the deadband the book is flat. Exits are trend-flip (relative momentum turns against the position) and an ATR trailing stop on the log-ratio (retrace of atr_stop_mult x mean |daily d log-ratio| from the best spread reached since entry). No time stop. The BTC hedge is submitted from the ETH fill event at the ACTUAL filled notional so the legs are dollar-matched, and it is closed with the ETH leg plus a per-bar reconciliation that never lets a hedge outlive its ETH leg. Three tuned parameters (lookback_days, deadband, atr_stop_mult); sizing and atr_period are frozen construction.

Verification Results

No functional impact: calculate_signal() has its own explicit guard (`if len(samples) < n_need: return 0.0`), so no trade fires before the buffer is full regardless of whether the override is honored. Optionally rename to avoid the shadow warning.

Verification Results

min_bars_required() override is flagged by static analysis as shadowing a framework method (the base may use its own warmup mechanism). If the override is ignored, warmup could differ from the intended lookback_days+2.

Verification Results

At the equity-based equal-notional sizing used here ($5 floor vs per-leg = 0.25*2.0*equity), this is practically unreachable, but for robustness consider closing the ETH leg if the hedge cannot be established.

Verification Results

In on_position_opened(), if the BTC hedge qty rounds to <= 0 (only when the equal-notional leg falls below the $5 min notional), the method returns leaving the ETH leg unhedged. _reconcile_legs() closes an orphaned hedge (hedge without ETH) but does NOT close an orphaned ETH leg (ETH without hedge), so the book could briefly carry naked directional ETH exposure.

Verification Results

This is the dollar-neutral long/short crypto-pair family whose recent full-history results have been weak (cointegration-spread abandons; L45 basket 0/N survivors). Sandbox Sharpe is only 0.35 with CI [-0.39, 1.07] straddling zero, and the 'normal' vol tercile returns -31% (calm +40.7%, stressed +39.8% carry the book). Profit factor 1.05 is in the marginal drag band. The mechanism is a genuinely new OHLCV expression (2-leg ratio-trend spread, not cross-sectional rank), so it merits a full backtest, but the analyst should scrutinize whether the ETH/BTC ratio-trend edge is real or concentrated in two favorable regimes. Impact is a non-issue here (impact_cost_pct 12.8%, capacity ~$6.1M on the two deepest contracts), so this is a gross-edge question, not a capacity/fee one.

Backtest Review

Positive, above-cost gross edge on a decisive sample: avg_trade_return_pct 0.34% is well above the 0.15% Binance USD-M floor, total_return +36% over 6.7 years, expectancy +$74.8/trade across 416 pair-trades. Commission is only 2.81% of gross and impact 15.95% (capacity ~$3.9M on the two deepest contracts), so this is NOT a fee/impact-fragility case — the edge is genuinely gross-positive, unlike the recent PF<1 dollar-neutral abandons (0.638/0.782/0.895).

Backtest Review

Genuinely new OHLCV mechanism (2-leg ETH/BTC ratio-trend CONTINUATION spread, not cross-sectional rank nor cointegration mean-reversion) — distinct from the L45/L68 families, and market-neutral so benchmark_meaningful=false is correct (judge on absolute risk-adjusted, not buy-hold).

Backtest Review

Code faithfully implements the hypothesis: 208 signaled = 208 submitted, balanced long/short legs, dollar-matched hedge submitted from the actual ETH fill, deadband + trend-flip + ATR-trailing exits as described. Fair test, not a broken mechanism. only_one_regime=false (profits in calm +14% and stressed +16.4%).

Backtest Review

Marginal risk-adjusted profile: profit_factor 1.037 sits in the [0.85,1.10] drag band (L18), Sharpe 0.347 with CI [-0.393, 1.08] straddling zero (not yet significant), max_drawdown 39% and recovery_factor 0.74.

Backtest Review

Edge is regime/year concentrated: the 'normal' vol tercile returns -1.9% (calm and stressed carry the book), and only 4 of 7 calendar years are positive (2020, 2023, 2024 negative). This is the dollar-neutral long/short crypto-pair family with a poor survivor rate (L45) — high risk of dying overfit in the 3-phase deflation.

Backtest Review

Much of the year-to-year return leans on a few large days (e.g. 2021-05-20 +29.6%, 2022-08-20 +21.9%, 2025-04-27 +18.3%).
Strategy report

Backtest and paper results are hypothetical. Trading involves risk of loss.