diff --git a/Empty.json b/Empty.json index 808716a..6d39cca 100644 --- a/Empty.json +++ b/Empty.json @@ -17,21 +17,20 @@ "max_open_trades": 20 }, "buy": { - "buy_deriv1_sma12d": -0.01, - "buy_deriv1_sma5d": -0.03, - "buy_deriv1_sma60": 0.0, - "buy_deriv2_sma12d": -0.07, - "buy_deriv2_sma5d": -0.04, - "buy_deriv2_sma60": 0.002 + "buy_deriv1_sma12d": -0.06, + "buy_deriv1_sma5d": -0.01, + "buy_deriv1_sma60": -0.003, + "buy_deriv2_sma12d": 0.0, + "buy_deriv2_sma5d": -0.07, + "buy_deriv2_sma60": -0.004 }, "protection": { - "drop_from_last_entry": 0.0 }, "sell": { - "sell_crossed_sma_indicators": "sma5_1d", - "sell_score_indicator": "sma5_score", - "sell_sma_indicators": "sma12_1d" + "sell_crossed_sma_indicators": "sma60", + "sell_score_indicator": "sma60_score", + "sell_sma_indicators": "sma48_1d" } }, "ft_stratparam_v": 1, diff --git a/Empty.py b/Empty.py index b1a76a1..a1563ab 100644 --- a/Empty.py +++ b/Empty.py @@ -550,9 +550,14 @@ class Empty(IStrategy): and (last_candle['sma12_deriv1_1d'] < 0.001 \ or last_candle['sma12_deriv2_1d'] < 0.001) else True - if condition and last_candle['range_pos'] > 0.05:# and self.pairs[pair]['force_stop']: - condition = last_candle['sma5'] > last_candle['sma60'] - + reason = '' + if not condition: + reason = 'lost' + if condition: + if last_candle['range_pos'] > 0.05:# and self.pairs[pair]['force_stop']: + condition = last_candle['sma5'] > last_candle['sma60'] + if not condition: + reason = 'range' # if self.pairs[pair]['force_stop'] and last_candle['range_pos'] < 0.02: # self.pairs[pair]['force_stop'] = False @@ -569,6 +574,8 @@ class Empty(IStrategy): print(f"Cool close date = trade={self.pairs[pair]['last_trade'].close_date} down {round(self.pairs[pair]['last_profit'], 3)} {cooldown_candles} {candles_since_close}") # self.should_enter_trade(pair, last_candle, current_time) + if self.pairs[pair]['stop']: + reason = 'stop' allow_to_buy = (condition and not self.pairs[pair]['stop']) | (entry_tag == 'force_entry') # force = self.pairs[pair]['force_buy'] @@ -578,6 +585,7 @@ class Empty(IStrategy): # else: # if not self.should_enter_trade(pair, last_candle, current_time): # allow_to_buy = False + dispo = round(self.wallets.get_available_stake_amount()) if allow_to_buy: self.pairs[pair]['first_buy'] = rate @@ -592,7 +600,6 @@ class Empty(IStrategy): self.pairs[pair]['last_min'] = min(last_candle['close'], self.pairs[pair]['last_min']) self.pairs[pair]['last_date'] = current_time - dispo = round(self.wallets.get_available_stake_amount()) # self.printLineLog() stake_amount = self.adjust_stake_amount(pair, last_candle) @@ -612,7 +619,19 @@ class Empty(IStrategy): buys=1, stake=round(stake_amount, 2) ) - + else: + self.log_trade( + last_candle=last_candle, + date=current_time, + action=("🟩Buy" if allow_to_buy else "Canceled") + " " + reason, + pair=pair, + rate=rate, + dispo=dispo, + profit=0, + trade_type=entry_tag, + buys=1, + stake=0 + ) return allow_to_buy def confirm_trade_exit(self, pair: str, trade: Trade, order_type: str, amount: float, rate: float, @@ -710,12 +729,12 @@ class Empty(IStrategy): cross = qtpylib.crossed_below(dataframe[self.sell_sma_indicators.value], dataframe[self.sell_crossed_sma_indicators.value]) - if profit > 0 and cross.iloc[-1]: - self.pairs[pair]['force_sell'] = True - return 'Cross' + # if profit > 0 and cross.iloc[-1]: + # self.pairs[pair]['force_sell'] = True + # return 'Cross' - if profit > max(5, expected_profit) and baisse > 0.30 and last_candle[f"close"] <= last_candle['sma5']\ - and last_candle['percent3'] < 0 and last_candle['percent5'] < 0: + if profit > max(5, expected_profit) and baisse > 0.30 and last_candle[f"close"] <= last_candle['sma36']: + # and last_candle['percent3'] < 0 and last_candle['percent5'] < 0: self.pairs[pair]['force_sell'] = True return 'B30' @@ -832,7 +851,9 @@ class Empty(IStrategy): informative[f"sma{timeperiod}"] = informative['mid'].ewm(span=timeperiod, adjust=False).mean() self.calculeDerivees(informative, f"sma{timeperiod}", timeframe=self.timeframe, ema_period=timeperiod) + informative[f"sma200"] = informative['mid'].ewm(span=200, adjust=False).mean() informative['rsi'] = talib.RSI(informative['close'], timeperiod=14) + self.calculeDerivees(informative, f"rsi", timeframe=self.timeframe, ema_period=14) informative['max_rsi_12'] = talib.MAX(informative['rsi'], timeperiod=12) informative['max_rsi_24'] = talib.MAX(informative['rsi'], timeperiod=24) @@ -848,6 +869,7 @@ class Empty(IStrategy): dataframe[f'stop_buying'] = qtpylib.crossed_below(dataframe[f"sma12"], dataframe['sma48']) + dataframe['atr'] = talib.ATR(dataframe) dataframe['rsi'] = talib.RSI(dataframe['close'], timeperiod=14) dataframe['max_rsi_12'] = talib.MAX(dataframe['rsi'], timeperiod=12) dataframe['max_rsi_24'] = talib.MAX(dataframe['rsi'], timeperiod=24) @@ -919,15 +941,17 @@ class Empty(IStrategy): #conditions.append((dataframe[self.stop_buying_indicator.value] == False) | (dataframe['range_pos'] < 0)) - conditions.append(dataframe['sma60_deriv1'] > self.buy_deriv1_sma60.value) + conditions.append(dataframe['sma12_deriv1'] > self.buy_deriv1_sma60.value) conditions.append(dataframe['sma5_deriv1_1d'] > self.buy_deriv1_sma5d.value) conditions.append(dataframe['sma12_deriv1_1d'] > self.buy_deriv1_sma12d.value) - conditions.append(dataframe['sma60_deriv2'] > self.buy_deriv1_sma60.value) - conditions.append(dataframe['sma5_deriv2_1d'] > self.buy_deriv1_sma5d.value) - conditions.append(dataframe['sma12_deriv2_1d'] > self.buy_deriv1_sma12d.value) + conditions.append(dataframe['sma12_deriv2'] > self.buy_deriv2_sma60.value) + conditions.append(dataframe['sma5_deriv2_1d'] > self.buy_deriv2_sma5d.value) + conditions.append(dataframe['sma12_deriv2_1d'] > self.buy_deriv2_sma12d.value) conditions.append(dataframe['hapercent'] > 0) + # conditions.append(dataframe['percent12'] < 0.01) + # conditions.append(dataframe['percent5'] < 0.01) conditions.append(dataframe['max_rsi_24'] < 80) conditions.append((dataframe['max_rsi_12_1d'] < 65))\ # | ( @@ -938,6 +962,8 @@ class Empty(IStrategy): conditions.append(dataframe[f"close"] > dataframe['sma60']) conditions.append(((dataframe[f"range_pos"] < 0.05) ) | ((dataframe['sma12_deriv1'] > 0) & (dataframe['sma12_deriv2'] > 0))) + conditions.append(dataframe['close_1d'] > dataframe['sma200_1d']) + # print(f"BUY indicators tested \n" # f"{self.buy_indicator0.value} {self.buy_crossed_indicator0.value} {self.buy_operator0.value} {self.buy_real_num0.value} \n" # f"{self.buy_indicator1.value} {self.buy_crossed_indicator1.value} {self.buy_operator1.value} {self.buy_real_num1.value} \n" @@ -1031,17 +1057,17 @@ class Empty(IStrategy): series = dataframe[f"{name}{suffixe}"] d1 = series.diff() d2 = d1.diff() - cond_bas = (d1.rolling(3).mean() > d1.rolling(10).mean()) - cond_haut = (d1.rolling(3).mean() < d1.rolling(10).mean()) - + pmin = int(ema_period / 3) + cond_bas = (d1.rolling(pmin).mean() > d1.rolling(ema_period).mean()) + cond_haut = (d1.rolling(pmin).mean() < d1.rolling(ema_period).mean()) dataframe[d1_col] = (dataframe[name] - dataframe[name].shift(3)) / dataframe[name].shift(3) dataframe[d2_col] = (dataframe[d1_col] - dataframe[d1_col].shift(1)) dataframe[f"{name}{suffixe}_inv"] = np.where(cond_bas, -1, np.where(cond_haut, 1, 0)) - short = d1.rolling(3).mean() - long = d1.rolling(10).mean() + short = d1.rolling(pmin).mean() + long = d1.rolling(ema_period).mean() spread = short - long zscore = (spread - spread.rolling(ema_period).mean()) / spread.rolling(ema_period).std() @@ -1131,13 +1157,13 @@ class Empty(IStrategy): f"{'rsi':>6}|" ) self.printLineLog() - df = pd.DataFrame.from_dict(self.pairs, orient='index') - colonnes_a_exclure = ['last_candle', - 'trade_info', 'last_date', 'last_count_of_buys', 'base_stake_amount', 'stop_buy'] - df_filtered = df[df['count_of_buys'] > 0].drop(columns=colonnes_a_exclure) - # df_filtered = df_filtered["first_buy", "last_max", "max_touch", "last_sell","last_buy", 'count_of_buys', 'current_profit'] - - print(df_filtered) + # df = pd.DataFrame.from_dict(self.pairs, orient='index') + # colonnes_a_exclure = ['last_candle', + # 'trade_info', 'last_date', 'last_count_of_buys', 'base_stake_amount', 'stop_buy'] + # df_filtered = df[df['count_of_buys'] > 0].drop(columns=colonnes_a_exclure) + # # df_filtered = df_filtered["first_buy", "last_max", "max_touch", "last_sell","last_buy", 'count_of_buys', 'current_profit'] + # + # print(df_filtered) self.columns_logged += 1 date = str(date)[:16] if date else "-" diff --git a/Empty.txt b/Empty.txt index 544c1ed..bdb4590 100644 --- a/Empty.txt +++ b/Empty.txt @@ -1,125 +1,154 @@ - BACKTESTING REPORT -┏━━━━━━━━━━┳━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┓ -┃ Pair ┃ Trades ┃ Avg Profit % ┃ Tot Profit USDT ┃ Tot Profit % ┃ Avg Duration ┃ Win Draw Loss Win% ┃ -┑━━━━━━━━━━╇━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━┩ -β”‚ BTC/USDT β”‚ 62 β”‚ 1.43 β”‚ 1238.641 β”‚ 123.86 β”‚ 2 days, 2:15:00 β”‚ 43 0 19 69.4 β”‚ -β”‚ TOTAL β”‚ 62 β”‚ 1.43 β”‚ 1238.641 β”‚ 123.86 β”‚ 2 days, 2:15:00 β”‚ 43 0 19 69.4 β”‚ -β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ - LEFT OPEN TRADES REPORT -┏━━━━━━━┳━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┓ -┃ Pair ┃ Trades ┃ Avg Profit % ┃ Tot Profit USDT ┃ Tot Profit % ┃ Avg Duration ┃ Win Draw Loss Win% ┃ -┑━━━━━━━╇━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━┩ -β”‚ TOTAL β”‚ 0 β”‚ 0.0 β”‚ 0.000 β”‚ 0.0 β”‚ 0:00 β”‚ 0 0 0 0 β”‚ -β””β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ - ENTER TAG STATS -┏━━━━━━━━━━━┳━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┓ -┃ Enter Tag ┃ Entries ┃ Avg Profit % ┃ Tot Profit USDT ┃ Tot Profit % ┃ Avg Duration ┃ Win Draw Loss Win% ┃ -┑━━━━━━━━━━━╇━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━┩ -β”‚ god β”‚ 62 β”‚ 1.43 β”‚ 1238.641 β”‚ 123.86 β”‚ 2 days, 2:15:00 β”‚ 43 0 19 69.4 β”‚ -β”‚ TOTAL β”‚ 62 β”‚ 1.43 β”‚ 1238.641 β”‚ 123.86 β”‚ 2 days, 2:15:00 β”‚ 43 0 19 69.4 β”‚ -β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ - EXIT REASON STATS -┏━━━━━━━━━━━━━┳━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┓ -┃ Exit Reason ┃ Exits ┃ Avg Profit % ┃ Tot Profit USDT ┃ Tot Profit % ┃ Avg Duration ┃ Win Draw Loss Win% ┃ -┑━━━━━━━━━━━━━╇━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━┩ -β”‚ B30 β”‚ 35 β”‚ 3.04 β”‚ 1581.248 β”‚ 158.12 β”‚ 2 days, 16:26:00 β”‚ 35 0 0 100 β”‚ -β”‚ Cross β”‚ 8 β”‚ 3.56 β”‚ 515.637 β”‚ 51.56 β”‚ 1 day, 8:45:00 β”‚ 8 0 0 100 β”‚ -β”‚ sma60 β”‚ 19 β”‚ -2.44 β”‚ -858.244 β”‚ -85.82 β”‚ 1 day, 7:32:00 β”‚ 0 0 19 0 β”‚ -β”‚ TOTAL β”‚ 62 β”‚ 1.43 β”‚ 1238.641 β”‚ 123.86 β”‚ 2 days, 2:15:00 β”‚ 43 0 19 69.4 β”‚ -β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ - MIXED TAG STATS -┏━━━━━━━━━━━┳━━━━━━━━━━━━━┳━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┓ -┃ Enter Tag ┃ Exit Reason ┃ Trades ┃ Avg Profit % ┃ Tot Profit USDT ┃ Tot Profit % ┃ Avg Duration ┃ Win Draw Loss Win% ┃ -┑━━━━━━━━━━━╇━━━━━━━━━━━━━╇━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━┩ -β”‚ god β”‚ B30 β”‚ 35 β”‚ 3.04 β”‚ 1581.248 β”‚ 158.12 β”‚ 2 days, 16:26:00 β”‚ 35 0 0 100 β”‚ -β”‚ god β”‚ Cross β”‚ 8 β”‚ 3.56 β”‚ 515.637 β”‚ 51.56 β”‚ 1 day, 8:45:00 β”‚ 8 0 0 100 β”‚ -β”‚ god β”‚ sma60 β”‚ 19 β”‚ -2.44 β”‚ -858.244 β”‚ -85.82 β”‚ 1 day, 7:32:00 β”‚ 0 0 19 0 β”‚ -β”‚ TOTAL β”‚ β”‚ 62 β”‚ 1.43 β”‚ 1238.641 β”‚ 123.86 β”‚ 2 days, 2:15:00 β”‚ 43 0 19 69.4 β”‚ -β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ - MONTH BREAKDOWN -┏━━━━━━━━━━━━┳━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┓ -┃ Month ┃ Trades ┃ Tot Profit USDT ┃ Profit Factor ┃ Win Draw Loss Win% ┃ -┑━━━━━━━━━━━━╇━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━┩ -β”‚ 31/01/2024 β”‚ 5 β”‚ 56.121 β”‚ 2.03 β”‚ 3 0 2 60.0 β”‚ -β”‚ 29/02/2024 β”‚ 0 β”‚ 0 β”‚ 0.0 β”‚ 0 0 0 0 β”‚ -β”‚ 31/03/2024 β”‚ 2 β”‚ 429.112 β”‚ 0.0 β”‚ 2 0 0 100 β”‚ -β”‚ 30/04/2024 β”‚ 5 β”‚ -0.991 β”‚ 0.99 β”‚ 3 0 2 60.0 β”‚ -β”‚ 31/05/2024 β”‚ 3 β”‚ 52.358 β”‚ 2.65 β”‚ 2 0 1 66.7 β”‚ -β”‚ 30/06/2024 β”‚ 3 β”‚ 14.301 β”‚ 1.44 β”‚ 2 0 1 66.7 β”‚ -β”‚ 31/07/2024 β”‚ 2 β”‚ 59.63 β”‚ 2.6 β”‚ 1 0 1 50.0 β”‚ -β”‚ 31/08/2024 β”‚ 1 β”‚ 65.81 β”‚ 0.0 β”‚ 1 0 0 100 β”‚ -β”‚ 30/09/2024 β”‚ 6 β”‚ 46.406 β”‚ 1.6 β”‚ 4 0 2 66.7 β”‚ -β”‚ 31/10/2024 β”‚ 2 β”‚ 70.475 β”‚ 0.0 β”‚ 2 0 0 100 β”‚ -β”‚ 30/11/2024 β”‚ 0 β”‚ 0 β”‚ 0.0 β”‚ 0 0 0 0 β”‚ -β”‚ 31/12/2024 β”‚ 0 β”‚ 0 β”‚ 0.0 β”‚ 0 0 0 0 β”‚ -β”‚ 31/01/2025 β”‚ 7 β”‚ 146.962 β”‚ 3.83 β”‚ 6 0 1 85.7 β”‚ -β”‚ 28/02/2025 β”‚ 0 β”‚ 0 β”‚ 0.0 β”‚ 0 0 0 0 β”‚ -β”‚ 31/03/2025 β”‚ 5 β”‚ -23.06 β”‚ 0.73 β”‚ 3 0 2 60.0 β”‚ -β”‚ 30/04/2025 β”‚ 2 β”‚ 43.195 β”‚ 1.89 β”‚ 1 0 1 50.0 β”‚ -β”‚ 31/05/2025 β”‚ 0 β”‚ 0 β”‚ 0.0 β”‚ 0 0 0 0 β”‚ -β”‚ 30/06/2025 β”‚ 2 β”‚ 27.632 β”‚ 1.57 β”‚ 1 0 1 50.0 β”‚ -β”‚ 31/07/2025 β”‚ 2 β”‚ 81.245 β”‚ 3.0 β”‚ 1 0 1 50.0 β”‚ -β”‚ 31/08/2025 β”‚ 3 β”‚ 123.165 β”‚ 0.0 β”‚ 3 0 0 100 β”‚ -β”‚ 30/09/2025 β”‚ 4 β”‚ 41.089 β”‚ 1.85 β”‚ 3 0 1 75.0 β”‚ -β”‚ 31/10/2025 β”‚ 4 β”‚ 137.411 β”‚ 3.73 β”‚ 3 0 1 75.0 β”‚ -β”‚ 30/11/2025 β”‚ 0 β”‚ 0 β”‚ 0.0 β”‚ 0 0 0 0 β”‚ -β”‚ 31/12/2025 β”‚ 2 β”‚ -171.727 β”‚ 0.0 β”‚ 0 0 2 0 β”‚ -β”‚ 31/01/2026 β”‚ 2 β”‚ 39.506 β”‚ 0.0 β”‚ 2 0 0 100 β”‚ -β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ +πŸ‘‰ Cette version est objectivement supΓ©rieure. + +MΓͺme si le CAGR bouge lΓ©gΓ¨rement, tout le reste s’amΓ©liore fortement. + +πŸ“Š Comparaison claire +Metric Avant Maintenant +Trades 95 53 +CAGR 21.38% 22.45% +Profit Factor 1.89 2.85 +SQN 1.87 2.38 +Winrate 48% 62% +Max DD 21.97% 7.37% +DD duration 309 jours 28 jours +Calmar 7.08 22.51 +πŸ”₯ Ce que Γ§a veut dire + +Le filtre structurel (SMA200 1D) a fait exactement ce qu’on attendait : + +Moins de trades + +Beaucoup moins de trades pourris + +Equity beaucoup plus lisse + +Bear market 2022 quasiment neutralisΓ© + +Et surtout : + +πŸ‘‰ Le drawdown long a disparu. + +C’est LE point critique. + +🧠 Lecture professionnelle + +Cette version est : + +Plus robuste + +Plus stable + +Plus exploitable en rΓ©el + +Psychologiquement viable + +Un DD de 309 jours casse un trader. +Un DD de 28 jours est gΓ©rable. + +🎯 Ce qui est trΓ¨s intΓ©ressant + +Regarde Γ§a : + +Worst trade passe de -4.55% β†’ -4.10% + +Profit factor explose Γ  2.85 + +Expectancy 24.77 (Γ©norme) + +Γ‡a veut dire que : + +πŸ‘‰ Tu trades maintenant uniquement les phases vraiment favorables. + +πŸ“‰ Le β€œun peu moins de gain” + +En rΓ©alitΓ© ton CAGR est mΓͺme lΓ©gΓ¨rement plus haut (22.45 vs 21.38). + +Mais mΓͺme si c’était un peu plus bas : + +RΓ©duire le drawdown de 22% Γ  7% vaut largement 2–3% de CAGR. + +Toujours. + +🧠 Ce que tu viens de faire + +Tu as transformΓ© une stratΓ©gie : + +Opportuniste + +en + +RΓ©gime-aware + +Et Γ§a change tout. + +⚠️ Maintenant la vraie question + +Veux-tu : + +πŸ”¬ Tester robustness (walk-forward) + +πŸ“ˆ Ajouter un lΓ©ger boost de performance + +βš–οΈ Ajouter un sizing adaptatif selon rΓ©gime + +πŸš€ Ajouter un second actif + +Parce que lΓ , on est Γ  l’étape β€œoptimisation fine”, plus β€œrΓ©paration”. + SUMMARY METRICS ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓ ┃ Metric ┃ Value ┃ ┑━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩ -β”‚ Backtesting from β”‚ 2024-01-01 00:00:00 β”‚ -β”‚ Backtesting to β”‚ 2026-02-25 00:00:00 β”‚ +β”‚ Backtesting from β”‚ 2022-01-01 00:00:00 β”‚ +β”‚ Backtesting to β”‚ 2026-02-20 00:00:00 β”‚ β”‚ Trading Mode β”‚ Spot β”‚ β”‚ Max open trades β”‚ 1 β”‚ β”‚ β”‚ β”‚ -β”‚ Total/Daily Avg Trades β”‚ 62 / 0.08 β”‚ +β”‚ Total/Daily Avg Trades β”‚ 53 / 0.04 β”‚ β”‚ Starting balance β”‚ 1000 USDT β”‚ -β”‚ Final balance β”‚ 2238.641 USDT β”‚ -β”‚ Absolute profit β”‚ 1238.641 USDT β”‚ -β”‚ Total profit % β”‚ 123.86% β”‚ -β”‚ CAGR % β”‚ 45.39% β”‚ -β”‚ Sortino β”‚ 1.74 β”‚ -β”‚ Sharpe β”‚ 0.45 β”‚ -β”‚ Calmar β”‚ 32.84 β”‚ -β”‚ SQN β”‚ 2.31 β”‚ -β”‚ Profit factor β”‚ 2.44 β”‚ -β”‚ Expectancy (Ratio) β”‚ 19.98 (0.44) β”‚ -β”‚ Avg. daily profit β”‚ 1.576 USDT β”‚ -β”‚ Avg. stake amount β”‚ 1797.064 USDT β”‚ -β”‚ Total trade volume β”‚ 224523.232 USDT β”‚ +β”‚ Final balance β”‚ 2312.665 USDT β”‚ +β”‚ Absolute profit β”‚ 1312.665 USDT β”‚ +β”‚ Total profit % β”‚ 131.27% β”‚ +β”‚ CAGR % β”‚ 22.45% β”‚ +β”‚ Sortino β”‚ 1.81 β”‚ +β”‚ Sharpe β”‚ 0.22 β”‚ +β”‚ Calmar β”‚ 22.51 β”‚ +β”‚ SQN β”‚ 2.38 β”‚ +β”‚ Profit factor β”‚ 2.85 β”‚ +β”‚ Expectancy (Ratio) β”‚ 24.77 (0.70) β”‚ +β”‚ Avg. daily profit β”‚ 0.869 USDT β”‚ +β”‚ Avg. stake amount β”‚ 1534.128 USDT β”‚ +β”‚ Total trade volume β”‚ 164258.371 USDT β”‚ β”‚ β”‚ β”‚ -β”‚ Best Pair β”‚ BTC/USDT 123.86% β”‚ -β”‚ Worst Pair β”‚ BTC/USDT 123.86% β”‚ +β”‚ Best Pair β”‚ BTC/USDT 131.27% β”‚ +β”‚ Worst Pair β”‚ BTC/USDT 131.27% β”‚ β”‚ Best trade β”‚ BTC/USDT 38.19% β”‚ -β”‚ Worst trade β”‚ BTC/USDT -4.55% β”‚ -β”‚ Best day β”‚ 403.713 USDT β”‚ -β”‚ Worst day β”‚ -108.048 USDT β”‚ -β”‚ Days win/draw/lose β”‚ 42 / 675 / 18 β”‚ -β”‚ Min/Max/Avg. Duration Winners β”‚ 0d 06:00 / 26d 20:00 / 2d 10:32 β”‚ -β”‚ Min/Max/Avg. Duration Losers β”‚ 0d 02:00 / 5d 12:00 / 1d 07:32 β”‚ -β”‚ Max Consecutive Wins / Loss β”‚ 10 / 3 β”‚ +β”‚ Worst trade β”‚ BTC/USDT -4.10% β”‚ +β”‚ Best day β”‚ 422.364 USDT β”‚ +β”‚ Worst day β”‚ -51.652 USDT β”‚ +β”‚ Days win/draw/lose β”‚ 33 / 901 / 19 β”‚ +β”‚ Min/Max/Avg. Duration Winners β”‚ 1d 03:00 / 28d 16:00 / 5d 13:35 β”‚ +β”‚ Min/Max/Avg. Duration Losers β”‚ 0d 01:00 / 6d 10:00 / 1d 13:21 β”‚ +β”‚ Max Consecutive Wins / Loss β”‚ 9 / 3 β”‚ β”‚ Rejected Entry signals β”‚ 0 β”‚ β”‚ Entry/Exit Timeouts β”‚ 0 / 0 β”‚ β”‚ β”‚ β”‚ -β”‚ Min balance β”‚ 1048.079 USDT β”‚ -β”‚ Max balance β”‚ 2421.125 USDT β”‚ -β”‚ Max % of account underwater β”‚ 9.17% β”‚ -β”‚ Absolute drawdown β”‚ 221.99 USDT (9.17%) β”‚ -β”‚ Drawdown duration β”‚ 46 days 16:00:00 β”‚ -β”‚ Profit at drawdown start β”‚ 1421.125 USDT β”‚ -β”‚ Profit at drawdown end β”‚ 1199.135 USDT β”‚ -β”‚ Drawdown start β”‚ 2025-10-27 00:00:00 β”‚ -β”‚ Drawdown end β”‚ 2025-12-12 16:00:00 β”‚ -β”‚ Market change β”‚ 51.20% β”‚ +β”‚ Min balance β”‚ 1003.126 USDT β”‚ +β”‚ Max balance β”‚ 2361.69 USDT β”‚ +β”‚ Max % of account underwater β”‚ 8.27% β”‚ +β”‚ Absolute drawdown β”‚ 116.751 USDT (7.37%) β”‚ +β”‚ Drawdown duration β”‚ 28 days 14:00:00 β”‚ +β”‚ Profit at drawdown start β”‚ 583.353 USDT β”‚ +β”‚ Profit at drawdown end β”‚ 466.603 USDT β”‚ +β”‚ Drawdown start β”‚ 2024-04-09 07:00:00 β”‚ +β”‚ Drawdown end β”‚ 2024-05-07 21:00:00 β”‚ +β”‚ Market change β”‚ 44.09% β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ -Backtested 2024-01-01 00:00:00 -> 2026-02-25 00:00:00 | Max open trades : 1 - STRATEGY SUMMARY -┏━━━━━━━━━━┳━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━┓ -┃ Strategy ┃ Trades ┃ Avg Profit % ┃ Tot Profit USDT ┃ Tot Profit % ┃ Avg Duration ┃ Win Draw Loss Win% ┃ Drawdown ┃ -┑━━━━━━━━━━╇━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━┩ -β”‚ Empty β”‚ 62 β”‚ 1.43 β”‚ 1238.641 β”‚ 123.86 β”‚ 2 days, 2:15:00 β”‚ 43 0 19 69.4 β”‚ 221.99 USDT 9.17% β”‚ -β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ +Backtested 2022-01-01 00:00:00 -> 2026-02-20 00:00:00 | Max open trades : 1 + STRATEGY SUMMARY +┏━━━━━━━━━━┳━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━┓ +┃ Strategy ┃ Trades ┃ Avg Profit % ┃ Tot Profit USDT ┃ Tot Profit % ┃ Avg Duration ┃ Win Draw Loss Win% ┃ Drawdown ┃ +┑━━━━━━━━━━╇━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━┩ +β”‚ Empty β”‚ 53 β”‚ 1.76 β”‚ 1312.665 β”‚ 131.27 β”‚ 4 days, 1:16:00 β”‚ 33 0 20 62.3 β”‚ 116.751 USDT 7.37% β”‚ +β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜