Basics
mode: futures
timeframe: 1h
interface version: 3
1h
Settings
stoploss: -0.05
has minimal roi
protections
process only new candles
startup candle count: 250
Indicators
RSI
SMA
talib
Concepts
mean_reversion
risk_management
trend_following
3 related strategies (⧉ identical code, ≈ similar name)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 | """ ShortKeltnerV1 — Inverse-Keltner short-side mean-reversion (bear-regime gated). Thesis (2026-05-28): Every short we killed (BearRegime, BearCrash, FundingShort) was TREND-FOLLOWING — it shorted breakdowns / fresh lows and got squeezed out by relief rallies. Post-mortem verdict: "entries happen at local-low prices that are about to mean-revert." This strategy shorts the OTHER side of that: it fades the relief RALLY. In a confirmed BTC downtrend, when a pair pokes above its upper Keltner band (overbought extreme) and rolls back below it, short the rejection. Structural inverse of the validated KeltnerBounceV1 long (FT-native PF 1.58, +51% / 3.3yr): the long enters on a cross *above* the lower band; this short enters on a cross *below* the upper band. Regime gate (v1.1, 2026-05-28): raw gate (close<SMA50 & <SMA200) was breakeven in the 2024/2025 bull because it shorted bull-market dips that ripped back. Added BTC SMA50 slope<0 (downtrend has direction) — true only in sustained downtrends, not bull pullbacks. Same slope filter as FundingFade gate-v2. Signal (futures SHORT): - REGIME GATE (BTC 1h): close < SMA50 AND close < SMA200 AND SMA50 sloping down (24h). - ENTRY: close crosses back below upper Keltner band (SMA25 + 2.5*ATR25) after poking above it (rally rejection). Confirm: volume > 1.75x vol_SMA20 AND RSI overbought (>60) within the prior 2 bars. - EXIT: fast ROI ladder + SL -5% + 36h time-stop + regime-flip (BTC reclaims SMA50) + pair oversold (RSI < 30). Sizing: 2x isolated leverage; stake / max_open from config. Generated 2026-05-28. """ import logging import pandas as pd import talib.abstract as ta from freqtrade.strategy import IStrategy, informative from pandas import DataFrame logger = logging.getLogger(__name__) class ShortKeltnerV1(IStrategy): INTERFACE_VERSION = 3 can_short = True trading_mode = "futures" margin_mode = "isolated" timeframe = "1h" minimal_roi = { "0": 0.06, "360": 0.04, "720": 0.025, "1440": 0.015, "2160": 0.0, } stoploss = -0.05 trailing_stop = False process_only_new_candles = True use_exit_signal = True exit_profit_only = False ignore_roi_if_entry_signal = False startup_candle_count = 250 kelt_period = 25 kelt_atr_mult = 2.5 vol_multiplier = 1.75 vol_sma_period = 20 rsi_overbought = 60 btc_slope_lookback = 24 @property def protections(self): return [ {"method": "CooldownPeriod", "stop_duration_candles": 4}, {"method": "StoplossGuard", "lookback_period_candles": 48, "trade_limit": 3, "stop_duration_candles": 24, "only_per_pair": False}, {"method": "MaxDrawdown", "lookback_period_candles": 72, "max_allowed_drawdown": 0.12, "stop_duration_candles": 48, "trade_limit": 2}, ] def leverage(self, pair, current_time, current_rate, proposed_leverage, max_leverage, entry_tag, side, **kwargs) -> float: return min(2.0, max_leverage) @informative("1h", "BTC/USDT:USDT") def populate_indicators_btc_1h(self, dataframe: DataFrame, metadata: dict) -> DataFrame: dataframe["sma50"] = ta.SMA(dataframe, timeperiod=50) dataframe["sma200"] = ta.SMA(dataframe, timeperiod=200) dataframe["sma50_slope"] = dataframe["sma50"] - dataframe["sma50"].shift(self.btc_slope_lookback) return dataframe def populate_indicators(self, dataframe: DataFrame, metadata: dict) -> DataFrame: sma = dataframe["close"].rolling(self.kelt_period).mean() atr = _atr(dataframe, self.kelt_period) dataframe["kelt_upper"] = sma + self.kelt_atr_mult * atr dataframe["vol_sma"] = dataframe["volume"].rolling(self.vol_sma_period).mean() dataframe["rsi"] = ta.RSI(dataframe, timeperiod=14) dataframe["btc_bear"] = ( (dataframe["btc_usdt_close_1h"] < dataframe["btc_usdt_sma50_1h"]) & (dataframe["btc_usdt_close_1h"] < dataframe["btc_usdt_sma200_1h"]) & (dataframe["btc_usdt_sma50_slope_1h"] < 0) ).astype(int) return dataframe def populate_entry_trend(self, dataframe: DataFrame, metadata: dict) -> DataFrame: rsi_was_overbought = ( (dataframe["rsi"].shift(1) > self.rsi_overbought) | (dataframe["rsi"].shift(2) > self.rsi_overbought) ) dataframe.loc[ ( (dataframe["close"] < dataframe["kelt_upper"]) & (dataframe["close"].shift(1) >= dataframe["kelt_upper"].shift(1)) & (dataframe["volume"] > self.vol_multiplier * dataframe["vol_sma"]) & rsi_was_overbought & (dataframe["btc_bear"] == 1) & (dataframe["volume"] > 0) ), ["enter_short", "enter_tag"], ] = (1, "kelt_upper_reject") return dataframe def populate_exit_trend(self, dataframe: DataFrame, metadata: dict) -> DataFrame: dataframe.loc[ ( ( (dataframe["btc_usdt_close_1h"] > dataframe["btc_usdt_sma50_1h"]) | (dataframe["rsi"] < 30) ) & (dataframe["volume"] > 0) ), ["exit_short", "exit_tag"], ] = (1, "regime_flip_or_oversold") return dataframe def custom_exit(self, pair, trade, current_time, current_rate, current_profit, **kwargs): if not trade.is_short: return None hours = (current_time - trade.open_date_utc).total_seconds() / 3600 if hours >= 36: return "time_exit_36h" return None def _atr(df: DataFrame, period: int) -> pd.Series: high = df["high"] low = df["low"] close = df["close"] tr = pd.concat( [high - low, (high - close.shift(1)).abs(), (low - close.shift(1)).abs()], axis=1, ).max(axis=1) return tr.rolling(period).mean() |
Strategy League — fixed backtest that feeds the ranking
Export report Freqtrade logsRun finished · took 38.6s
pairs 33 pairs
timerange 20210101-20260101
mode futures
timeframe 1h
stake 100 USDT
wallet 1000 USDT
max open trades 10
fee exchange lowest tier
total profit+6.20%
final wallet1062 USDT
win rate44.7%
max drawdown-11.02%
market change+442.71%
vs market-436.51%
timeframe1h
profit factor1.07
expectancy ratio0.038
break-even fee0.1341%
sharpe0.145
sortino0.342
CAGR+1.2%
calmar0.588
avg leverage2.0x
avg MFE+2.08%
avg MAE-1.97%
avg profit/trade0.14%
avg duration3h 48m
best trade+6.19%
worst trade-5.41%
win/loss streak9 / 10
positive months29/59
consistent (3-mo)43.9%
worst 3-mo-5.31%
trades459
revision1
likely annual return+1%
range (5th–95th)-2% … +5%
chance of profit72.5%
worst-5% outcome-3%
significance (p)0.2644
risk of ruin0.0%
- profit isn't statistically significant (p=0.26) — hard to tell apart from luck
- did not beat simply holding the market
Resampling the trade sequence 2,000× shows the spread of results this edge could plausibly produce — separating a dependable strategy from one that got lucky once.
Loading charts…
Monthly breakdown
| Month | Regime | Trades | Profit % | Avg % | Win | Loss | Win % | DD % | Avg dur |
|---|---|---|---|---|---|---|---|---|---|
| Dec 2025 | bearish trending low vol | 12 | +0.07 | 0.06 | 6 | 6 | 50.0 | -0.88 | 6h 10m |
| Nov 2025 | bearish trending high vol | 16 | +4.96 | 3.10 | 12 | 4 | 75.0 | -2.27 | 1h 56m |
| Oct 2025 | bearish trending low vol | 7 | +3.58 | 5.13 | 7 | 0 | 100.0 | -5.22 | 3h 51m |
| Sep 2025 | bullish choppy low vol | 2 | -0.96 | -5.20 | 0 | 2 | 0.0 | -5.8 | 1h 00m |
| Aug 2025 | bearish choppy low vol | 3 | +1.15 | 3.81 | 2 | 1 | 66.7 | -6.03 | 2h 20m |
| Jul 2025 | bullish choppy low vol | 5 | -0.71 | -1.46 | 1 | 4 | 20.0 | -5.99 | 4h 36m |
| Jun 2025 | bearish choppy low vol | 4 | -0.55 | -1.39 | 1 | 3 | 25.0 | -5.3 | 5h 45m |
| May 2025 | bullish trending low vol | 5 | -0.38 | -0.74 | 2 | 3 | 40.0 | -4.99 | 5h 48m |
| Apr 2025 | bullish choppy low vol | 3 | -1.43 | -5.06 | 0 | 3 | 0.0 | -4.4 | 3h 20m |
| Mar 2025 | bearish trending high vol | 2 | +1.09 | 5.49 | 2 | 0 | 100.0 | -3.59 | 5h 00m |
| Feb 2025 | bearish trending low vol | 14 | +1.03 | 0.76 | 8 | 6 | 57.1 | -5.17 | 7h 17m |
| Dec 2024 | bullish trending low vol | 16 | -5.15 | -3.27 | 2 | 14 | 12.5 | -5.06 | 1h 15m |
| Nov 2024 | bullish trending low vol | 3 | -0.09 | -0.33 | 1 | 2 | 33.3 | -0.67 | 2h 00m |
| Oct 2024 | bullish choppy low vol | 4 | +1.77 | 4.50 | 4 | 0 | 100.0 | -0.87 | 7h 00m |
| Sep 2024 | bearish choppy low vol | 7 | -0.34 | -0.49 | 2 | 5 | 28.6 | -1.26 | 7h 43m |
| Aug 2024 | bearish choppy high vol | 9 | +1.63 | 1.85 | 6 | 3 | 66.7 | -1.5 | 2h 47m |
| Jul 2024 | bearish trending low vol | 7 | +0.06 | 0.10 | 3 | 4 | 42.9 | -2.33 | 6h 34m |
| Jun 2024 | bearish choppy low vol | 16 | +3.50 | 2.21 | 11 | 5 | 68.8 | -5.95 | 3h 45m |
| May 2024 | bullish choppy high vol | 11 | -0.13 | -0.12 | 5 | 6 | 45.5 | -6.69 | 4h 44m |
| Apr 2024 | bearish choppy high vol | 2 | +0.06 | 0.30 | 1 | 1 | 50.0 | -5.17 | 8h 30m |
| Mar 2024 | bullish trending high vol | 4 | +1.86 | 4.68 | 4 | 0 | 100.0 | -6.66 | 4h 15m |
| Feb 2024 | bullish trending low vol | 6 | -1.16 | -1.94 | 2 | 4 | 33.3 | -7.04 | 5h 50m |
| Jan 2024 | bearish choppy high vol | 5 | -0.56 | -1.11 | 2 | 3 | 40.0 | -6.38 | 2h 36m |
| Dec 2023 | bullish trending low vol | 19 | +3.48 | 1.84 | 12 | 7 | 63.2 | -8.68 | 2h 57m |
| Nov 2023 | bullish trending low vol | 5 | +0.81 | 1.62 | 2 | 3 | 40.0 | -9.34 | 2h 24m |
| Oct 2023 | bullish trending low vol | 1 | +0.60 | 5.99 | 1 | 0 | 100.0 | -9.55 | 4h 00m |
| Sep 2023 | bearish choppy low vol | 20 | -3.03 | -1.52 | 4 | 16 | 20.0 | -10.14 | 5h 12m |
| Aug 2023 | bearish choppy low vol | 13 | +1.09 | 0.84 | 7 | 6 | 53.8 | -8.15 | 5h 23m |
| Jul 2023 | bullish trending low vol | 12 | -0.97 | -0.81 | 4 | 8 | 33.3 | -8.66 | 4h 50m |
| Jun 2023 | bullish trending low vol | 4 | +1.02 | 2.54 | 2 | 2 | 50.0 | -8.34 | 1h 30m |
| May 2023 | bearish choppy low vol | 10 | -1.05 | -1.06 | 2 | 8 | 20.0 | -8.29 | 4h 42m |
| Apr 2023 | bullish trending low vol | 10 | -0.34 | -0.34 | 3 | 7 | 30.0 | -7.94 | 4h 30m |
| Mar 2023 | bullish trending high vol | 3 | +0.33 | 1.10 | 2 | 1 | 66.7 | -7.76 | 7h 20m |
| Feb 2023 | bullish trending low vol | 7 | -0.29 | -0.41 | 3 | 4 | 42.9 | -7.81 | 3h 17m |
| Jan 2023 | bullish trending low vol | 1 | -0.12 | -1.24 | 0 | 1 | 0.0 | -6.97 | 1h 00m |
| Dec 2022 | bearish trending low vol | 2 | -0.24 | -1.22 | 0 | 2 | 0.0 | -6.85 | 5h 00m |
| Nov 2022 | bearish trending high vol | 12 | +0.86 | 0.72 | 7 | 5 | 58.3 | -9.26 | 3h 40m |
| Oct 2022 | bullish choppy low vol | 9 | -1.60 | -1.79 | 2 | 7 | 22.2 | -7.45 | 6h 20m |
| Sep 2022 | bearish choppy high vol | 25 | +1.40 | 0.56 | 12 | 13 | 48.0 | -6.82 | 3h 19m |
| Aug 2022 | bullish choppy high vol | 22 | +2.12 | 0.97 | 10 | 12 | 45.5 | -11.02 | 3h 55m |
| Jul 2022 | bullish trending high vol | 1 | +0.40 | 4.00 | 1 | 0 | 100.0 | -9.32 | 6h 00m |
| Jun 2022 | bearish trending high vol | 6 | -1.32 | -2.19 | 2 | 4 | 33.3 | -10.3 | 1h 50m |
| May 2022 | bearish trending high vol | 6 | +0.92 | 1.53 | 3 | 3 | 50.0 | -9.62 | 2h 10m |
| Apr 2022 | bearish choppy high vol | 8 | -0.35 | -0.44 | 3 | 5 | 37.5 | -9.33 | 3h 38m |
| Mar 2022 | bullish choppy high vol | 2 | -0.77 | -3.87 | 0 | 2 | 0.0 | -8.99 | 1h 00m |
| Feb 2022 | bearish trending high vol | 4 | -0.96 | -2.39 | 1 | 3 | 25.0 | -8.82 | 2h 00m |
| Jan 2022 | bearish trending high vol | 7 | -1.02 | -1.49 | 1 | 6 | 14.3 | -7.81 | 3h 34m |
| Dec 2021 | bearish trending high vol | 4 | -1.48 | -3.75 | 1 | 3 | 25.0 | -6.31 | 1h 30m |
| Nov 2021 | bearish trending high vol | 13 | -0.68 | -0.48 | 5 | 8 | 38.5 | -5.77 | 2h 42m |
| Oct 2021 | bullish trending high vol | 7 | +0.25 | 0.71 | 4 | 3 | 57.1 | -4.75 | 4h 51m |
| Sep 2021 | bearish trending high vol | 7 | +1.75 | 2.51 | 5 | 2 | 71.4 | -6.66 | 1h 51m |
| Aug 2021 | bullish trending high vol | 9 | +0.74 | 0.82 | 5 | 4 | 55.6 | -6.8 | 2h 20m |
| Jul 2021 | bullish trending high vol | 9 | -2.82 | -3.15 | 2 | 7 | 22.2 | -7.66 | 4h 53m |
| Jun 2021 | bearish trending high vol | 2 | +0.07 | 0.41 | 1 | 1 | 50.0 | -4.7 | 4h 00m |
| May 2021 | bearish trending high vol | 14 | -2.56 | -1.96 | 4 | 10 | 28.6 | -4.19 | 0h 26m |
| Apr 2021 | bearish choppy high vol | 5 | -1.44 | -2.88 | 1 | 4 | 20.0 | -1.77 | 1h 00m |
| Mar 2021 | bullish choppy high vol | 6 | +1.41 | 2.49 | 4 | 2 | 66.7 | -2.35 | 3h 30m |
| Feb 2021 | bullish trending high vol | 3 | -0.09 | -0.29 | 1 | 2 | 33.3 | -1.66 | 2h 40m |
| Jan 2021 | bullish trending high vol | 8 | +0.77 | 0.98 | 4 | 4 | 50.0 | -1.58 | 1h 08m |
Yearly breakdown
| Year | Trades | Profit % | Avg % | Win | Loss | Win % | DD % | Avg dur |
|---|---|---|---|---|---|---|---|---|
| 2025 | 73 | +7.85 | 1.06 | 41 | 32 | 56.2 | -6.03 | 4h 38m |
| 2024 | 90 | +1.45 | 0.16 | 43 | 47 | 47.8 | -7.04 | 4h 09m |
| 2023 | 105 | +1.53 | 0.14 | 42 | 63 | 40.0 | -10.14 | 4h 16m |
| 2022 | 104 | -0.56 | -0.06 | 42 | 62 | 40.4 | -11.02 | 3h 36m |
| 2021 | 87 | -4.08 | -0.45 | 37 | 50 | 42.5 | -7.66 | 2h 25m |
Trade charts — best 2 and worst 2 performing pairs (full OHLC candles are expensive to render for every pair)
Backtests — over a market period
Backtest this strategy over a chosen crypto-cycle period. These don't affect the League ranking, and need that period's candle data downloaded.
Log in or sign up to run backtests.
| Period | Range | Total % | Win % | Max DD | Trades | |
|---|---|---|---|---|---|---|
| 2020 · DeFi Summer & Pre-Halving Rally | 20200101-20210101 | not run | ||||
| 2021 · Institutional Bull Market | 20210101-20220101 | not run | ||||
| 2022 · Post-Bull Crash & Macro Tightening | 20220101-20230101 | not run | ||||
| 2023–2024 · Recovery & ETF Anticipation | 20230101-20250101 | not run | ||||
| 2025–2026 · Current Cycle | 20250101-20260101 | not run | ||||
Walk forward
Out-of-sample backtest on recent data · 33 pairs · 20260101-20260701.
Backtest trust check
no lookahead patterns · 1 thing(s) worth reviewing before trusting the numbers
| Line | Pattern | Detail | |
|---|---|---|---|
| 117 | review | enter_tag_overwrite | enter_tag/exit_tag is written by 2 separate assignments -- they share one column and run in source order, so a row matching more than one condition keeps only the LAST tag. Per-tag statistics won't mean what they appear to |
ran by Ron · took s
Lookahead analysis
freqtrade lookahead-analysis: detects strategies peeking at future candles.