From c93c97c2ded30ca676f0ecf0d92947225cfc7c27 Mon Sep 17 00:00:00 2001 From: Matthias Date: Sat, 2 Aug 2025 09:41:06 +0200 Subject: [PATCH] fix: tick_size_over_time must not use scientific notion closes 12054 --- freqtrade/data/btanalysis/historic_precision.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/freqtrade/data/btanalysis/historic_precision.py b/freqtrade/data/btanalysis/historic_precision.py index c8aa4fbee..9aa43fa6a 100644 --- a/freqtrade/data/btanalysis/historic_precision.py +++ b/freqtrade/data/btanalysis/historic_precision.py @@ -11,7 +11,7 @@ def get_tick_size_over_time(candles: DataFrame) -> Series: # count the number of significant digits for the open and close prices for col in ["open", "high", "low", "close"]: candles[f"{col}_count"] = ( - candles[col].round(14).astype(str).str.extract(r"\.(\d*[1-9])")[0].str.len() + candles[col].round(14).apply("{:.15f}".format).str.extract(r"\.(\d*[1-9])")[0].str.len() ) candles["max_count"] = candles[["open_count", "close_count", "high_count", "low_count"]].max( axis=1