Skip to content

View original

AdaFourHourHeikinAshiConsecutiveGreenTrendLong

Hypotheses

ADA 4H Heikin-Ashi Consecutive Green Candle Trend-Continuation Long-Only on ADAUSDT.BINANCE

Hypotheses

A long-only, single-instrument Heikin-Ashi candlestick pattern strategy on ADAUSDT.BINANCE — confirmed testable per the 11+ recent successful ADA-4H single-instrument pipeline additions (Donchian breakout, weekend calendar, vol contraction, RSI divergence, MACD crossover, OBV divergence, Parabolic SAR, Aroon all backtested cleanly on ADA-4H bars alone — establishing this as THE most reliable testable single-instrument setup). Structurally distinct from every prior ADA pipeline strategy by using the HEIKIN-ASHI TRANSFORMED bar series rather than raw OHLCV indicators. Heikin-Ashi (Nison 2001 'Japanese Candlestick Charting Techniques'; popularized in Western technical analysis via Linda Raschke and Larry Williams) constructs SYNTHETIC candles from the raw OHLCV using these formulas: ha_close = (open + high + low + close) / 4 (averaging the 4 prices), ha_open = (previous_ha_open + previous_ha_close) / 2 (averaging previous synthetic open and close), ha_high = max(high, ha_open, ha_close), ha_low = min(low, ha_open, ha_close). This SMOOTHING transformation removes single-bar noise — synthetic candles that show consistent direction (5+ consecutive green HA candles) indicate a sustained trend that's harder to fake than raw price movements. The strategy enters LONG when N consecutive green HA candles form WITH the 200-SMA trend filter confirming the long-term direction. This is structurally distinct from all prior ADA strategies: those use numerical oscillators (RSI, MACD, OBV, Aroon), adaptive trailing stops (SAR), or fixed channels (Donchian) — this transforms the BAR SERIES ITSELF and reads a color-pattern signal from the transformed series. The mathematical effect is similar to applying a 2-bar exponential smoothing to OHLC values, producing cleaner trend visualization with empirically distinct signal timing (~0.4 correlation with raw-price-based indicators). Uses ONLY ADAUSDT.BINANCE 4H bars. Fills critical gaps: (1) FIRST HEIKIN-ASHI strategy in portfolio (entirely new mathematical signal class — bar-transformation rather than indicator-derivation), (2) Long-only matching the proven directional asymmetry, (3) Single-instrument simplicity, (4) Confirmed-testable instrument. Position sizing: 18% per trade. Risk per trade: ~1.5% capped by stop-loss.

Hypotheses

Iteration 2 fix for the Layer-2 'frozen signal' failure on steady_downtrend: the prior code gated calculate_signal to a constant 0.0 whenever the entry condition wasn't met, so a perpetual downtrend produced 294 identical zeros. The signal now returns a continuous SIGNED Heikin-Ashi run length every bar (+k for green runs, -k for red runs), which varies in every regime — in a steady downtrend it grows progressively more negative rather than staying flat. The entry gate (>= streak_threshold green candles AND close > SMA) moved into should_enter via thresholding against the matching-unit streak_threshold, plus a stored self._trend_ok SMA flag, so no entry/exit behavior changed and all earlier-passing layers (Layer 1 static, imports, structure) stay intact. Only calculate_signal's return shape, the cached _trend_ok flag, and should_enter's condition were edited.

Hypotheses

The Heikin-Ashi consecutive-green trend-continuation premise is falsified on ADA 4H. The strategy is decisively negative — Sharpe -2.17 with the ENTIRE confidence interval below zero (ci_high -0.50), probabilistic_sharpe 0.0066, profit_factor 0.68, win_rate 28.6%, sortino -4.42, expectancy -$81/trade, total_return -33.3% — and loses money in 7 of 8 years (only 2025 positive) over a large 413-trade sample, so this is persistent edge failure, not noise or a regime artifact. The code is correct (proper HA transform, long-only spot, avg_position_pct ≈ intended 18%, no leverage/stacking artifact), so the failure is the mechanism itself: entering after 5+ consecutive green HA candles buys late into an exhausted move and exiting on the first red HA candle sells right at the reversal, producing systematic whipsaw (max 15 consecutive losses); Heikin-Ashi smoothing only delays the entry further. No parameter change can lift a strategy whose Sharpe CI is entirely below zero — raising streak_threshold enters even later, lowering it adds chop. Not worth optimizing — abandon. (Secondary: commission is 16.8% of gross, but the gross edge is already negative, so fees are not the cause.)

Implementation

Long-only Heikin-Ashi trend-continuation on ADAUSDT 4H spot bars. Transforms raw OHLCV into synthetic Heikin-Ashi candles (smoothing single-bar noise) and trades a consecutive-green-candle pattern. The signal is the SIGNED HA run length (+k consecutive green / -k consecutive red), continuous and varying every bar. Enters LONG when >=streak_threshold consecutive green HA candles form while raw close is above the 200-SMA uptrend filter. Exits on the first red HA candle, a close back below the SMA, or a stop-loss. Sizes 18% of equity notional, no leverage (spot CASH).

Verification Results

Verification failed (Layer 2 — synthetic scenarios): Parameters used: ['sma_period', 'min_notional', 'position_pct', 'stop_loss_pct', 'streak_threshold'] Check that __init__ sets all attributes from self.parameters.get(). - steady_downtrend: Frozen signal: all 294 signals are identical (value=0.0). calculate_signal() likely has a bug — the signal never varies.

Backtest Review

Clean implementation matching the hypothesis: correct Heikin-Ashi transform, long-only spot (avg_position_pct 18.7% ≈ intended 18%, no leverage/stacking artifact), 413 entries — no code bug.

Backtest Review

Correct venue routing (long-only no-leverage on BINANCE_SPOT) and a large, decisive sample.

Backtest Review

metrics_reliable=true, end_unrealized 0 — the result is a true realized track record, not a paper-profit headline.

Backtest Review

Decisively negative: Sharpe -2.17 with the entire CI below zero (ci_high -0.50), probabilistic_sharpe 0.0066, profit_factor 0.68, win_rate 28.6%, sortino -4.42, expectancy -$81/trade, total_return -33.3%.

Backtest Review

Loses money in 7 of 8 years (only 2025 positive) — persistent premise failure, not a regime fluke.

Backtest Review

Mechanism is backwards in practice: entering after 5+ green HA candles buys late into an extended move and exiting on the first red HA candle sells at the turn — whipsaw (28.6% win rate, 15 consecutive losses); HA smoothing delays entry and worsens it.

Backtest Review

Costs add insult (commission 16.84% of gross) but are not the cause — the gross edge is negative.

Outcome Summary

This was the portfolio's first Heikin-Ashi strategy, entering ADA spot long after 5+ consecutive green synthetic candles in a confirmed 200-SMA uptrend, on the thesis that HA smoothing reveals harder-to-fake trends. The implementation was faithful and the sample large (413 trades), but it was decisively unprofitable — Sharpe -2.17 with the whole confidence interval below zero, profit factor 0.68, 28.6% win rate, -33.3% total return, and losses in seven of eight years. The analyst abandoned it at the backtest-review gate on its second iteration, concluding the mechanism is backwards (smoothing delays entry into exhausted moves and exits at the reversal, causing whipsaw and 15 consecutive losses) and that this is a persistent premise failure rather than a cost or regime artifact, so it never reached optimization or risk review.

Outcome Summary

Heikin-Ashi smoothing delays signal timing, so a 'consecutive green candle' trend-continuation entry buys late into exhausted moves and exits at the turn — a structurally backwards mechanism on ADA 4H whose gross edge was negative before costs, meaning the bar-transformation novelty added no edge.

Outcome Summary

The backtest-review analyst issued an 'abandon' verdict: the code was correct (proper HA transform, long-only spot, sizing ≈18%, no artifacts), so the failure is the mechanism itself — entering after 5+ green HA candles buys late into an exhausted move and exiting on the first red candle sells right at the reversal, producing systematic whipsaw that no parameter change can fix given a Sharpe CI entirely below zero.

Outcome Summary

A long-only, single-instrument Heikin-Ashi trend-continuation strategy on ADAUSDT Binance spot 4H bars (18% sizing, no leverage), entering long after 5+ consecutive green Heikin-Ashi candles while a 200-SMA uptrend filter confirmed, and exiting on the first red HA candle, a close back below the SMA, or a stop-loss.

Outcome Summary

Over a large 413-trade sample it returned -33.3% with Sharpe -2.17 (entire CI below zero, ci_high -0.50), probabilistic Sharpe 0.0066, profit factor 0.68, win rate 28.6%, Sortino -4.42, expectancy -$81/trade and a 38.8% max drawdown, with 15 consecutive losses and money lost in 7 of 8 years (only 2025 positive).
Strategy report

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