test: reduce ta-lib test accuracy to align with ta-lib 0.6.5

Precision for ta-lib 0.6.x was increased
but is lower by 0001 than what was in the freqtrade ta-lib fix

https://github.com/TA-Lib/ta-lib/blob/main/src/ta_func/ta_utility.h#L257

This won't be a problem for any normal usdt pair.
shitcoins on some exchanges (e.g gate) with 12 zeros before the first significant digit wouldn't have worked today, either.
This commit is contained in:
Matthias
2025-08-14 09:59:07 +02:00
parent 091d1c2d55
commit 3e3f092f0c

View File

@@ -5,11 +5,11 @@ import talib.abstract as ta
def test_talib_bollingerbands_near_zero_values(): def test_talib_bollingerbands_near_zero_values():
inputs = pd.DataFrame( inputs = pd.DataFrame(
[ [
{"close": 0.00000010}, {"close": 0.000010},
{"close": 0.00000011}, {"close": 0.000011},
{"close": 0.00000012}, {"close": 0.000012},
{"close": 0.00000013}, {"close": 0.000013},
{"close": 0.00000014}, {"close": 0.000014},
] ]
) )
bollinger = ta.BBANDS(inputs, matype=0, timeperiod=2) bollinger = ta.BBANDS(inputs, matype=0, timeperiod=2)