Fix bug in volumepairlist if lookback is bigger than the available candles (new pairs)

closes #9154
This commit is contained in:
Matthias
2023-09-06 19:40:31 +02:00
parent 8cbb5d2a93
commit 20cca01d10

View File

@@ -260,6 +260,7 @@ class VolumePairList(IPairList):
quoteVolume = (pair_candles['quoteVolume']
.rolling(self._lookback_period)
.sum()
.fillna(0)
.iloc[-1])
# replace quoteVolume with range quoteVolume sum calculated above