Skip to content

View original

AvaxLeverageRegimeGatedMomentumLS

Hypotheses

Leverage-Regime-Gated Momentum, Long-Short (Single-Instrument AVAXUSDT.BINANCE USD-M — Trade 4H Price Momentum ONLY When Perp FUNDING Magnitude Signals a LEVERAGED / Trending Regime; Stand Aside When Funding Is Flat = Range Regime, Trailing-Stop Winners, 2-Parameter)

Hypotheses

A LONG-SHORT, SINGLE-INSTRUMENT, SINGLE-VENUE momentum strategy on AVAXUSDT.BINANCE USD-M that leans on the factory's ONLY proven archetype — 4H momentum with trailing stops (the single Sharpe-~2 survivor) — but gates it with a genuinely ORTHOGONAL, data-SAFE REGIME filter that is NOT a second price series and NOT the taker-flow confirmation that already collided-and-died. The gate is perpetual FUNDING MAGNITUDE, the one supplementary feed confirmed dense and reliable multi-year in the sandbox. Economic premise: momentum persists in LEVERAGED, directional regimes and mean-reverts / whipsaws in balanced ones. When funding carries a strong bias (large |funding| vs its own rolling norm), the market is leverage-driven and one-sided — the environment where trends extend and momentum pays. When funding sits near zero (balanced books), price action is choppy and momentum entries bleed on whipsaw. So we take momentum trades ONLY inside the leveraged regime and stand flat otherwise. This is deliberately the MIRROR of the pending neutral-funding-gated spot mean-reversion (that trades reversion in the FLAT-funding range regime; this trades continuation in the BIASED-funding trend regime) — opposite regime, opposite mechanism, opposite venue/direction — and a different family from the dead positioning-contrarian, forced-flow-reversal, and funding-euphoria-de-risk lines. Data-safe: funding is multi-year-dense; single venue + single instrument on 4H bars → all data jointly available in Layer-3 (no cross-venue, options, OI, or liquidation feed to fail). Deliberately 2-parameter to resist the overfit deaths that dominate the log.

Hypotheses

I verified the data and pre-tested the mechanism on six years of real bars before writing code, and BOTH checks came back strongly positive — this is the first hypothesis in my recent batch where the edge is clearly present rather than at the noise boundary. DATA: AVAX funding is dense and complete (6,232 parquet prints at 1,095/year with no holes, 2020-09 to 2026-05), and because the primary venue is USD-M BINANCE the loader also resolves the DB-backed series, which runs to 2026-08-01. So unlike the spot-venue case there is no tail gap and no need for an extra funding leg: walk-forward windows and the 15-day holdout can all be populated, and single-venue/single-instrument means everything is jointly available in Layer 3. MECHANISM: an event study over 2020-2026 shows the funding-magnitude gate separating momentum outcomes exactly as the hypothesis predicts. With a 48h momentum lookback and |mom|>=1.0, direction-adjusted forward returns are +1.900% at 48h (t=+4.9) in the LEVERAGED bucket versus -0.084% (t=-0.3) in the flat-funding bucket, against +0.924% ungated; at 168h it is +7.766% (t=+8.6) leveraged versus +1.381% flat. The flat bucket being statistically ZERO at the 48-96h horizons is the hypothesis's own 'momentum bleeds on whipsaw in balanced books' claim showing up independently, and it is what makes the gate additive rather than cosmetic. LEVERAGED beats flat in 28 of 30 cells across the 48h and 96h momentum lookbacks, and the largest t is 10.6 against an expected maximum of ~3.2 under pure noise for the number of cells scanned — comfortably clear of the multiple-testing bar that the three strategies I just abandoned all failed (each peaked at or below its noise maximum). Notably the effect is ABSENT at the 24h lookback (leveraged is negative at 12-24h there), which is economically coherent rather than convenient: leverage-driven trends are multi-day phenomena, and that non-monotonicity is a structural fact I fixed the lookback to rather than searched over. DESIGN CHOICES: the exit is a trailing stop rather than a fixed horizon because the horizon table shows returns still compounding at 168h (+7.8%), so a time stop would cut the fat tail that carries the edge — this also matches the factory's one proven archetype. The gate is RELATIVE (bias versus its own trailing mean absolute level), not a fixed rate band, because AVAX funding ran far hotter in 2021 than today and an absolute threshold would silently select one epoch; this is the failure mode behind my lesson on absolute supplementary thresholds. The signal is continuous and returned every bar rather than gated behind the entry condition, and the momentum and regime conditions are combined multiplicatively into ONE thresholded score rather than ANDed as two independent gates, so this is not the compound-gate pattern that fires zero times in a short sandbox window. Only 2 parameters are exposed as tunables (entry_z and trail_atr); lev_ratio is deliberately FIXED at its structurally motivated 1.3 so the regime definition itself cannot be fitted to the sample. Fee viability is not marginal: +1.33% to +1.90% gross per trade against the 0.10% USD-M round trip is more than 10x the 0.15% floor, and the ~40 trades/year implied by the trigger count keeps turnover low enough that fee drag is immaterial. Warmup is ~180 bars (30 days) against a 365-day sandbox window and per-bar cost is O(1) with forward-only pointers and running sums, so neither the zero-trade nor the timeout failure mode applies. Leverage is left at 1.0 and never referenced in sizing — risk-based sizing against a ~8% ATR stop already produces roughly half of equity in notional, so declaring leverage above 1 would be inert and would trip the leverage_set_but_unused gate.

Hypotheses

Outlier-driven, regime-fragile momentum edge that has decayed to negative and will not clear post-optimization robustness gates. Sharpe 0.403 with 95% CI [-0.223, 1.050] straddling zero, profit_factor 1.15 (below the 1.2 meaningful line), information_ratio -0.40, and max_drawdown 46.3% (CI high 85.3%) — far too deep for a supposedly regime-filtered momentum strategy. The entire 194.5% headline comes from just two years (2021 +251%, 2023 +70.6%) built on single-day spikes on illiquid early-AVAX (2021-01-22 +85.2%, 2021-08-26 +82.1%, 2023-01-29 +53.9%; return_kurtosis 22.6), while EVERY other year loses and the last three full years (2024 -14.6%, 2025 -21.2%, 2026 -13.0%) are all negative — the mechanism has stopped working in the modern regime. Nearly half the headline (end_unrealized_pct 45.8) is an un-exited open position, not realized edge. This is the funding-gated-momentum family (OHLCV+funding continuation clone, L9/L41, zero survivors; sibling to two candidates abandoned this session); the funding gate did not deliver the promised steadiness. The 15-day holdout falls in the negative 2026 period, and best-of-225 selection would tune to the 2021 outliers and near-certainly fail deflated-Sharpe/holdout in ANALYZING. avg_trade_return_pct 3.13% clears the fee floor, so this is overfit/regime-fragility, not fee-fragility, and there is no robust parameter region to tune toward. Abandon at BACKTEST_REVIEW rather than spend 2 hours.

Implementation

Long-short, single-instrument momentum strategy on AVAXUSDT.BINANCE USD-M, 4-HOUR bars, gated by perpetual funding MAGNITUDE. Each bar it folds in every funding print stamped at or before the bar (forward-only pointer, strictly non-anticipating) and forms two quantities: a volatility-normalised trend, mom_z = (close/close[-12] - 1) / realised 48h vol, and a leverage-regime weight, regime_w = 0.5*(1 + tanh((ratio - lev_ratio)/regime_smooth)) where ratio = |mean of the last 3 funding prints| / mean(|funding|) over the last 90 prints (~30 days). calculate_signal returns mom_z * regime_w every bar: the sign is the trend direction, the magnitude is scaled toward zero when funding is flat (balanced books, where momentum whipsaws). It goes long when that score clears +0.6 and short when it clears -0.6, so a strong price trend inside a balanced regime cannot trigger a trade. The exit is a pure TRAILING STOP at 3.0 ATR from the best price reached since entry, adapting to current volatility, with a 120-bar (20-day) backstop and no profit target — the measured edge keeps compounding past the entry horizon, so winners are ridden. Size risks 4% of equity against the initial trailing-stop distance, capped at 1.0x equity; leverage is 1.0 and is not referenced in sizing.

Verification Results

At backtest review, verify the full 2020-2026 run reproduces the leveraged-bucket edge (much of it lives in 2021-2022 high-funding regimes the sandbox under-samples). If full-window PF/Sharpe stays near break-even, abandon.

Verification Results

SANDBOX IS NEAR BREAK-EVEN AND CONTRADICTS THE MOTIVATING EVENT STUDY. The developer's 6-year event study shows a strong leveraged-regime edge (+1.9% at 48h t=+4.9; +7.8% at 168h t=+8.6; largest t=10.6 vs ~3.2 noise max), but the 363-day sandbox returns Sharpe 0.163, PF 1.044, win_rate 0.28, +3.73% over just 25 trades, Sharpe CI [-1.57, +1.62] straddling zero, and long trades weak (1/9). Plausibly a regime artifact — the recent compressed-funding window rarely produces a strong leveraged reading, so the multiplicative gate fires few high-conviction trends and the outlier winners dominate (skew +2.12, kurtosis 22.5). NOT a code defect and NOT a data ceiling (AVAX funding complete 2020-2026, so walk-forward + holdout can be populated).

Verification Results

Confirm enough trades per walk-forward window; treat a holdout with only a few trades as inconclusive.

Verification Results

LOW TRADE FREQUENCY — 25 trades/363 days (~25/yr) extrapolates to ~150 over the full 6-year window, above the measurability floor, but each of the 3 walk-forward OOS windows and the 15-day holdout will be thin, making OOS Sharpe estimates noisy for a low-win-rate trailing-stop payoff.

Verification Results

No action; confirms intended fail-safe behavior.

Verification Results

Layer-2 synthetic frozen 0.0 signal across all scenarios is expected/benign — the proxy supplies no funding, so the strategy correctly stands aside instead of trading ungated momentum. The real-funding sandbox produced 25 trades (funding_events_available 724), proving the path is live.

Backtest Review

Clean, data-safe construction: single venue, single instrument, dense multi-year funding feed — verification-safe, orthogonal regime source

Backtest Review

Deliberately 2 tunables (lev_ratio held fixed) to resist overfitting

Backtest Review

avg_trade_return_pct 3.13% clears the futures fee floor, so failure is not fee-fragility

Backtest Review

Risk sizing against the trailing stop is sound in construction

Backtest Review

Sharpe 0.403 with 95% CI [-0.223, 1.050] straddles zero; profit_factor 1.15 below the 1.2 meaningful line

Backtest Review

Entire return comes from 2021 (+251%) and 2023 (+70.6%); EVERY other year is negative including the last three full years (2024 -14.6%, 2025 -21.2%, 2026 -13.0%) — the edge has decayed in the modern regime

Backtest Review

Outlier-driven: return_kurtosis 22.6, skew 2.17, with +85%/+82%/+54% single-day book gains on illiquid early-AVAX (2021, 2023) carrying the record

Backtest Review

max_drawdown 46.3% (CI high 85.3%) — the funding gate did not deliver the promised steadiness for a 'regime-filtered' momentum strategy

Backtest Review

end_unrealized_pct 45.8 — nearly half the headline return is an un-exited open position at backtest end, not realized edge

Backtest Review

148 trades over 6 years is the L41 mid-count momentum-overfit signature; the 15-day holdout falls in the negative 2026 period

Outcome Summary

This strategy paired the factory's only proven archetype — 4H momentum with a trailing stop — with a genuinely orthogonal, data-safe regime gate: trade momentum only when perpetual funding magnitude signals a leveraged, trending regime and stand aside in flat-funding chop, explicitly the mirror of a neutral-funding mean-reversion sibling. The construction was clean and verification-safe on AVAX's dense multi-year funding feed, but the backtest exposed a fragile edge: a Sharpe straddling zero, profit factor 1.15, and a 46% drawdown, with the entire +194.5% return coming from 2021 and 2023 single-day spikes on illiquid early-AVAX while every other year — including the last three full years — lost money and half the headline was an open unrealized position. The analyst abandoned it at backtest review as an outlier-driven, regime-decayed member of the zero-survivor funding-gated-momentum family, judging the funding gate did not deliver the promised steadiness and that optimization would merely overfit the 2021 outliers into a certain later abandon.

Outcome Summary

A funding-magnitude regime gate does not rescue momentum from outlier-dependence or regime decay — a headline built on a couple of illiquid early-AVAX years with every recent year negative, a 46% drawdown, and nearly half the return sitting in an un-exited open position is a fragile, non-generalizing edge with no robust parameter region to optimize toward.

Outcome Summary

It was abandoned at the BACKTEST_REVIEW gate: a Sharpe straddling zero, profit factor below 1.2, and a 46% drawdown mean the funding gate did not deliver the promised steadiness, and the edge has decayed to negative in the modern regime with the headline resting on 2021/2023 outliers. As a member of the zero-survivor funding-gated-momentum family with the 15-day holdout falling in the negative 2026 period, best-of-N optimization would tune to the 2021 spikes and near-certainly fail the deflated-Sharpe/holdout gates, so it never reached optimization.

Outcome Summary

A long-short, single-instrument, single-venue momentum strategy on AVAXUSDT.BINANCE USD-M that leans on the factory's proven 4H-momentum-with-trailing-stop archetype but gates it on perpetual funding magnitude as an orthogonal regime filter — trading momentum only when funding bias is large relative to its own rolling norm (a leveraged, trending regime) and standing aside when funding is flat (a balanced, chop-prone regime), riding winners with an ATR trailing stop.

Outcome Summary

The backtest was outlier-driven and regime-fragile: total return +194.5% but Sharpe only 0.403 (CI [-0.223, 1.050] straddling zero), profit factor 1.15 (below the 1.2 line), max drawdown 46.3% (CI to 85.3%), and information ratio -0.40 over 148 trades. The entire headline came from 2021 (+251%) and 2023 (+70.6%) built on single-day spikes on illiquid early-AVAX (kurtosis 22.6), while every other year lost — including the last three full years (2024 -14.6%, 2025 -21.2%, 2026 -13.0%) — and nearly half the return (end_unrealized_pct 45.8) was an un-exited open position.
Strategy report

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