15 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 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 | # --- Do not remove these libs --- # --- Do not remove these libs --- from freqtrade.strategy.interface import IStrategy from typing import Dict, List from functools import reduce from pandas import DataFrame # -------------------------------- import talib.abstract as ta import numpy as np import freqtrade.vendor.qtpylib.indicators as qtpylib import datetime from technical.util import resample_to_interval, resampled_merge from datetime import datetime, timedelta from freqtrade.persistence import Trade from freqtrade.strategy import stoploss_from_open, merge_informative_pair, DecimalParameter, IntParameter, CategoricalParameter import technical.indicators as ftt # @Rallipanos # # Buy hyperspace params: # entry_params = { # "base_nb_candles_entry": 14, # "ewo_high": 2.327, # "ewo_high_2": -2.327, # "ewo_low": -20.988, # "low_offset": 0.975, # "low_offset_2": 0.955, # "rsi_entry": 69 # } # # Buy hyperspace params: # entry_params = { # "base_nb_candles_entry": 18, # "ewo_high": 3.422, # "ewo_high_2": -3.436, # "ewo_low": -8.562, # "low_offset": 0.966, # "low_offset_2": 0.959, # "rsi_entry": 66, # } # # # Sell hyperspace params: # # exit_params = { # # "base_nb_candles_exit": 17, # # "high_offset": 0.997, # # "high_offset_2": 1.01, # # } # # Sell hyperspace params: # exit_params = { # "base_nb_candles_exit": 7, # "high_offset": 1.014, # "high_offset_2": 0.995, # } # # Buy hyperspace params: # entry_params = { # "ewo_high_2": -5.642, # "low_offset_2": 0.951, # "rsi_entry": 54, # "base_nb_candles_entry": 16, # value loaded from strategy # "ewo_high": 3.422, # value loaded from strategy # "ewo_low": -8.562, # value loaded from strategy # "low_offset": 0.966, # value loaded from strategy # } # # Sell hyperspace params: # exit_params = { # "base_nb_candles_exit": 8, # "high_offset_2": 1.002, # "high_offset": 1.014, # value loaded from strategy # } # Buy hyperspace params: # value loaded from strategy # value loaded from strategy # value loaded from strategy # value loaded from strategy entry_params = {'base_nb_candles_entry': 8, 'ewo_high': 4.179, 'ewo_low': -16.917, 'ewo_high_2': -2.609, 'low_offset': 0.986, 'low_offset_2': 0.944, 'rsi_entry': 58} # Sell hyperspace params: # value loaded from strategy exit_params = {'base_nb_candles_exit': 16, 'high_offset': 1.054, 'high_offset_2': 1.018} def EWO(dataframe, ema_length=5, ema2_length=35): df = dataframe.copy() ema1 = ta.EMA(df, timeperiod=ema_length) ema2 = ta.EMA(df, timeperiod=ema2_length) emadif = (ema1 - ema2) / df['low'] * 100 return emadif class NotAnotherSMAOffsetStrategyHOv3(IStrategy): INTERFACE_VERSION = 3 # ROI table: # "0": 0.283, # "40": 0.086, # "99": 0.036, minimal_roi = {'0': 10} # Stoploss: stoploss = -0.3 # SMAOffset base_nb_candles_entry = IntParameter(2, 20, default=entry_params['base_nb_candles_entry'], space='entry', optimize=False) base_nb_candles_exit = IntParameter(10, 40, default=exit_params['base_nb_candles_exit'], space='exit', optimize=False) low_offset = DecimalParameter(0.9, 0.99, default=entry_params['low_offset'], space='entry', optimize=False) low_offset_2 = DecimalParameter(0.9, 0.99, default=entry_params['low_offset_2'], space='entry', optimize=False) high_offset = DecimalParameter(0.95, 1.1, default=exit_params['high_offset'], space='exit', optimize=False) high_offset_2 = DecimalParameter(0.99, 1.5, default=exit_params['high_offset_2'], space='exit', optimize=False) # Protection fast_ewo = 50 slow_ewo = 200 ewo_low = DecimalParameter(-20.0, -8.0, default=entry_params['ewo_low'], space='entry', optimize=False) ewo_high = DecimalParameter(2.0, 12.0, default=entry_params['ewo_high'], space='entry', optimize=False) ewo_high_2 = DecimalParameter(-6.0, 12.0, default=entry_params['ewo_high_2'], space='entry', optimize=False) rsi_entry = IntParameter(30, 70, default=entry_params['rsi_entry'], space='entry', optimize=True) # Trailing stop: trailing_stop = True trailing_stop_positive = 0.005 trailing_stop_positive_offset = 0.025 trailing_only_offset_is_reached = True # Sell signal use_exit_signal = True exit_profit_only = False exit_profit_offset = 0.01 ignore_roi_if_entry_signal = False # Optional order time in force. order_time_in_force = {'entry': 'gtc', 'exit': 'ioc'} # Optimal timeframe for the strategy timeframe = '5m' inf_1h = '1h' process_only_new_candles = True startup_candle_count = 200 use_custom_stoploss = False plot_config = {'main_plot': {'ma_entry': {'color': 'orange'}, 'ma_exit': {'color': 'orange'}}} slippage_protection = {'retries': 3, 'max_slippage': -0.02} entry_signals = {} def confirm_trade_exit(self, pair: str, trade: Trade, order_type: str, amount: float, rate: float, time_in_force: str, exit_reason: str, current_time: datetime, **kwargs) -> bool: dataframe, _ = self.dp.get_analyzed_dataframe(pair, self.timeframe) last_candle = dataframe.iloc[-1] if last_candle is not None: if exit_reason in ['exit_signal']: if last_candle['hma_50'] * 1.149 > last_candle['ema_100'] and last_candle['close'] < last_candle['ema_100'] * 0.951: # *1.2 return False # slippage try: state = self.slippage_protection['__pair_retries'] except KeyError: state = self.slippage_protection['__pair_retries'] = {} candle = dataframe.iloc[-1].squeeze() slippage = rate / candle['close'] - 1 if slippage < self.slippage_protection['max_slippage']: pair_retries = state.get(pair, 0) if pair_retries < self.slippage_protection['retries']: state[pair] = pair_retries + 1 return False state[pair] = 0 return True def populate_indicators(self, dataframe: DataFrame, metadata: dict) -> DataFrame: # Calculate all ma_entry values for val in self.base_nb_candles_entry.range: dataframe[f'ma_entry_{val}'] = ta.EMA(dataframe, timeperiod=val) # Calculate all ma_exit values for val in self.base_nb_candles_exit.range: dataframe[f'ma_exit_{val}'] = ta.EMA(dataframe, timeperiod=val) dataframe['hma_50'] = qtpylib.hull_moving_average(dataframe['close'], window=50) dataframe['ema_100'] = ta.EMA(dataframe, timeperiod=100) dataframe['sma_9'] = ta.SMA(dataframe, timeperiod=9) # Elliot dataframe['EWO'] = EWO(dataframe, self.fast_ewo, self.slow_ewo) # RSI dataframe['rsi'] = ta.RSI(dataframe, timeperiod=14) dataframe['rsi_fast'] = ta.RSI(dataframe, timeperiod=4) dataframe['rsi_slow'] = ta.RSI(dataframe, timeperiod=20) return dataframe def populate_entry_trend(self, dataframe: DataFrame, metadata: dict) -> DataFrame: dataframe.loc[(dataframe['rsi_fast'] < 35) & (dataframe['close'] < dataframe[f'ma_entry_{self.base_nb_candles_entry.value}'] * self.low_offset.value) & (dataframe['EWO'] > self.ewo_high.value) & (dataframe['rsi'] < self.rsi_entry.value) & (dataframe['volume'] > 0) & (dataframe['close'] < dataframe[f'ma_exit_{self.base_nb_candles_exit.value}'] * self.high_offset.value), ['enter_long', 'enter_tag']] = (1, 'ewo1') dataframe.loc[(dataframe['rsi_fast'] < 35) & (dataframe['close'] < dataframe[f'ma_entry_{self.base_nb_candles_entry.value}'] * self.low_offset_2.value) & (dataframe['EWO'] > self.ewo_high_2.value) & (dataframe['rsi'] < self.rsi_entry.value) & (dataframe['volume'] > 0) & (dataframe['close'] < dataframe[f'ma_exit_{self.base_nb_candles_exit.value}'] * self.high_offset.value) & (dataframe['rsi'] < 25), ['enter_long', 'enter_tag']] = (1, 'ewo2') dataframe.loc[(dataframe['rsi_fast'] < 35) & (dataframe['close'] < dataframe[f'ma_entry_{self.base_nb_candles_entry.value}'] * self.low_offset.value) & (dataframe['EWO'] < self.ewo_low.value) & (dataframe['volume'] > 0) & (dataframe['close'] < dataframe[f'ma_exit_{self.base_nb_candles_exit.value}'] * self.high_offset.value), ['enter_long', 'enter_tag']] = (1, 'ewolow') return dataframe def populate_exit_trend(self, dataframe: DataFrame, metadata: dict) -> DataFrame: conditions = [] conditions.append((dataframe['close'] > dataframe['sma_9']) & (dataframe['close'] > dataframe[f'ma_exit_{self.base_nb_candles_exit.value}'] * self.high_offset_2.value) & (dataframe['rsi'] > 50) & (dataframe['volume'] > 0) & (dataframe['rsi_fast'] > dataframe['rsi_slow']) | (dataframe['close'] < dataframe['hma_50']) & (dataframe['close'] > dataframe[f'ma_exit_{self.base_nb_candles_exit.value}'] * self.high_offset.value) & (dataframe['volume'] > 0) & (dataframe['rsi_fast'] > dataframe['rsi_slow'])) if conditions: dataframe.loc[reduce(lambda x, y: x | y, conditions), 'exit_long'] = 1 return dataframe |
Strategy League — fixed backtest that feeds the ranking
Export report Freqtrade logsRun finished · took 283.3s
ℹ️ This strategy uses a trailing stop — freqtrade only
re-checks these once per 5m candle by default, not against the price movement within it.
For a more accurate read, re-run this backtest locally with --timeframe-detail 1m. Freqle doesn't do this for every check here: multiplying every
League/sweep backtest by a finer detail timeframe is more compute than the sandbox can sustain
across every indexed strategy. why this matters →
- did not beat simply holding the market
- statistically significant edge (p=0.00)
- 100% of resampled runs stayed profitable
- profitable across 90% of rolling 3-month windows
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 | 1 | -0.05 | -0.48 | 0 | 1 | 0.0 | -0.43 | 13h 15m |
| Nov 2025 | bearish trending high vol | 64 | +6.91 | 1.08 | 52 | 12 | 81.2 | -0.66 | 3h 08m |
| Oct 2025 | bearish trending low vol | 75 | +14.05 | 1.87 | 65 | 10 | 86.7 | -3.49 | 1h 37m |
| Sep 2025 | bullish choppy low vol | 11 | +0.21 | 0.19 | 8 | 3 | 72.7 | -0.7 | 2h 12m |
| Aug 2025 | bullish choppy low vol | 4 | -0.11 | -0.27 | 3 | 1 | 75.0 | -0.7 | 19h 22m |
| Jul 2025 | bullish choppy low vol | 18 | +2.43 | 1.35 | 14 | 4 | 77.8 | -1.13 | 7h 56m |
| Jun 2025 | bearish choppy low vol | 13 | -1.56 | -1.20 | 9 | 4 | 69.2 | -1.34 | 14h 45m |
| May 2025 | bullish trending low vol | 12 | +2.55 | 2.13 | 11 | 1 | 91.7 | -1.38 | 8h 11m |
| Apr 2025 | bullish choppy low vol | 4 | -0.01 | -0.01 | 3 | 1 | 75.0 | -1.56 | 2h 11m |
| Mar 2025 | bearish trending high vol | 13 | -1.01 | -0.78 | 8 | 5 | 61.5 | -1.43 | 10h 23m |
| Feb 2025 | bearish trending low vol | 6 | +0.29 | 0.49 | 5 | 1 | 83.3 | -1.19 | 7h 07m |
| Jan 2025 | bearish choppy low vol | 12 | -2.15 | -1.79 | 7 | 5 | 58.3 | -1.25 | 10h 37m |
| Dec 2024 | bullish trending low vol | 72 | +4.59 | 0.64 | 55 | 17 | 76.4 | -0.84 | 2h 50m |
| Nov 2024 | bullish trending low vol | 144 | +13.48 | 0.94 | 111 | 33 | 77.1 | -0.57 | 4h 00m |
| Oct 2024 | bullish choppy low vol | 3 | -0.17 | -0.58 | 2 | 1 | 66.7 | -0.24 | 30h 47m |
| Sep 2024 | bearish choppy low vol | 2 | -0.13 | -0.65 | 1 | 1 | 50.0 | -0.11 | 30h 02m |
| Aug 2024 | bearish choppy high vol | 5 | +0.13 | 0.26 | 3 | 2 | 60.0 | -0.15 | 2h 55m |
| Jul 2024 | bearish trending low vol | 2 | +0.46 | 2.30 | 2 | 0 | 100.0 | 0.0 | 2h 45m |
| Jun 2024 | bearish choppy low vol | 54 | +8.91 | 1.65 | 53 | 1 | 98.1 | -1.14 | 2h 58m |
| May 2024 | bullish choppy high vol | 4 | +0.54 | 1.34 | 3 | 1 | 75.0 | -1.31 | 9h 09m |
| Apr 2024 | bearish choppy high vol | 8 | -4.46 | -5.57 | 5 | 3 | 62.5 | -1.34 | 5h 48m |
| Mar 2024 | bullish trending high vol | 37 | +4.76 | 1.29 | 30 | 7 | 81.1 | -0.24 | 4h 42m |
| Feb 2024 | bullish trending low vol | 29 | +4.88 | 1.68 | 24 | 5 | 82.8 | -0.38 | 2h 37m |
| Jan 2024 | bearish choppy high vol | 52 | +6.13 | 1.18 | 43 | 9 | 82.7 | -0.45 | 6h 56m |
| Dec 2023 | bullish trending low vol | 73 | +5.36 | 0.73 | 58 | 15 | 79.5 | -0.67 | 7h 25m |
| Nov 2023 | bullish trending low vol | 36 | +4.20 | 1.17 | 30 | 6 | 83.3 | -0.28 | 5h 31m |
| Oct 2023 | bullish trending low vol | 4 | +0.84 | 2.10 | 3 | 1 | 75.0 | -0.04 | 6h 30m |
| Sep 2023 | bearish choppy low vol | 2 | +0.50 | 2.48 | 2 | 0 | 100.0 | -0.0 | 2h 10m |
| Aug 2023 | bearish choppy low vol | 43 | +4.16 | 0.97 | 39 | 4 | 90.7 | -1.04 | 1h 28m |
| Jul 2023 | bullish trending low vol | 26 | -1.02 | -0.39 | 15 | 11 | 57.7 | -0.72 | 15h 22m |
| Jun 2023 | bullish trending low vol | 47 | +8.62 | 1.83 | 41 | 6 | 87.2 | -0.88 | 3h 26m |
| May 2023 | bearish choppy low vol | 2 | +0.40 | 1.98 | 2 | 0 | 100.0 | -1.11 | 1h 52m |
| Apr 2023 | bullish trending low vol | 7 | +1.43 | 2.04 | 6 | 1 | 85.7 | -1.67 | 3h 03m |
| Mar 2023 | bullish trending high vol | 16 | -5.02 | -3.14 | 8 | 8 | 50.0 | -1.61 | 35h 47m |
| Feb 2023 | bullish trending low vol | 8 | +1.41 | 1.76 | 7 | 1 | 87.5 | -0.06 | 2h 36m |
| Jan 2023 | bullish trending low vol | 48 | +6.62 | 1.38 | 37 | 11 | 77.1 | -0.31 | 5h 49m |
| Dec 2022 | bearish trending low vol | 4 | +0.72 | 1.79 | 4 | 0 | 100.0 | 0.0 | 0h 00m |
| Nov 2022 | bearish trending high vol | 50 | +7.91 | 1.58 | 43 | 7 | 86.0 | -1.07 | 4h 13m |
| Oct 2022 | bullish choppy low vol | 8 | -0.86 | -1.07 | 5 | 3 | 62.5 | -0.68 | 4h 41m |
| Sep 2022 | bearish choppy high vol | 10 | -0.75 | -0.75 | 5 | 5 | 50.0 | -0.45 | 11h 12m |
| Aug 2022 | bullish choppy high vol | 15 | -0.15 | -0.10 | 11 | 4 | 73.3 | -0.79 | 4h 34m |
| Jul 2022 | bearish trending high vol | 42 | +4.69 | 1.12 | 32 | 10 | 76.2 | -1.79 | 8h 01m |
| Jun 2022 | bearish trending high vol | 41 | -1.32 | -0.32 | 25 | 16 | 61.0 | -2.07 | 4h 06m |
| May 2022 | bearish trending high vol | 54 | +4.70 | 0.87 | 42 | 12 | 77.8 | -1.3 | 3h 24m |
| Apr 2022 | bearish choppy high vol | 9 | +1.05 | 1.16 | 6 | 3 | 66.7 | -0.12 | 3h 05m |
| Mar 2022 | bullish choppy high vol | 15 | +2.86 | 1.91 | 13 | 2 | 86.7 | -0.09 | 2h 26m |
| Feb 2022 | bearish trending high vol | 26 | +5.38 | 2.07 | 21 | 5 | 80.8 | -0.64 | 1h 09m |
| Jan 2022 | bearish trending high vol | 7 | +1.77 | 2.53 | 6 | 1 | 85.7 | -1.05 | 6h 37m |
| Dec 2021 | bearish trending high vol | 17 | -0.49 | -0.30 | 12 | 5 | 70.6 | -1.61 | 4h 44m |
| Nov 2021 | bullish trending high vol | 18 | +1.24 | 0.69 | 15 | 3 | 83.3 | -1.46 | 6h 07m |
| Oct 2021 | bullish trending high vol | 45 | +3.58 | 0.79 | 39 | 6 | 86.7 | -1.4 | 5h 18m |
| Sep 2021 | bearish trending high vol | 81 | +13.81 | 1.71 | 68 | 13 | 84.0 | -0.58 | 1h 49m |
| Aug 2021 | bullish trending high vol | 66 | +8.87 | 1.34 | 53 | 13 | 80.3 | -0.85 | 2h 59m |
| Jul 2021 | bearish trending high vol | 38 | +1.30 | 0.34 | 26 | 12 | 68.4 | -0.98 | 8h 26m |
| Jun 2021 | bearish trending high vol | 38 | +1.17 | 0.31 | 22 | 16 | 57.9 | -0.88 | 5h 22m |
| May 2021 | bearish trending high vol | 372 | +55.72 | 1.50 | 319 | 53 | 85.8 | -1.39 | 1h 38m |
| Apr 2021 | bearish choppy high vol | 200 | +16.07 | 0.80 | 151 | 49 | 75.5 | -2.0 | 2h 00m |
| Mar 2021 | bullish choppy high vol | 95 | +10.99 | 1.16 | 81 | 14 | 85.3 | -2.95 | 3h 45m |
| Feb 2021 | bullish trending high vol | 309 | +28.66 | 0.93 | 251 | 58 | 81.2 | -3.8 | 2h 28m |
| Jan 2021 | bullish trending high vol | 407 | +49.59 | 1.22 | 337 | 70 | 82.8 | -7.6 | 1h 38m |
Yearly breakdown
| Year | Trades | Profit % | Avg % | Win | Loss | Win % | DD % | Avg dur |
|---|---|---|---|---|---|---|---|---|
| 2025 | 233 | +21.55 | 0.92 | 185 | 48 | 79.4 | -3.49 | 5h 05m |
| 2024 | 412 | +39.12 | 0.95 | 332 | 80 | 80.6 | -1.34 | 4h 23m |
| 2023 | 312 | +27.50 | 0.88 | 248 | 64 | 79.5 | -1.67 | 7h 21m |
| 2022 | 281 | +26.00 | 0.93 | 213 | 68 | 75.8 | -2.07 | 4h 29m |
| 2021 | 1686 | +190.51 | 1.13 | 1374 | 312 | 81.5 | -7.6 | 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 · 2 thing(s) worth reviewing before trusting the numbers
| Line | Pattern | Detail | |
|---|---|---|---|
| 122 | review | startup_candles_too_small | startup_candle_count is 200, but EMA(timeperiod=100) needing 3x warmup needs at least 300 candles -- so the first 100+ candles of every backtest use an indicator that hasn't warmed up. Recursive indicators (EMA/RSI/ADX/ATR) want several times their period, not exactly it |
| 169 | review | enter_tag_overwrite | enter_tag/exit_tag is written by 3 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.