From 363098d32dcb729f4b6f3e3e2aadae492c97138e Mon Sep 17 00:00:00 2001 From: froggleston Date: Wed, 18 May 2022 12:56:43 +0100 Subject: [PATCH] Fix reversed makr/funding_rate columns --- freqtrade/optimize/backtesting.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/freqtrade/optimize/backtesting.py b/freqtrade/optimize/backtesting.py index 78faf65be..a80266b2c 100755 --- a/freqtrade/optimize/backtesting.py +++ b/freqtrade/optimize/backtesting.py @@ -297,12 +297,12 @@ class Backtesting: if "futures_funding_rate" in self.config: self.futures_data[pair] = mark_rates_dict[pair].merge( funding_rates_dict[pair], on='date', - how="outer", suffixes=["_fund", "_mark"]).fillna( + how="outer", suffixes=["_mark", "_fund"]).fillna( self.config.get('futures_funding_rate')) else: self.futures_data[pair] = mark_rates_dict[pair].merge( funding_rates_dict[pair], on='date', - how="inner", suffixes=["_fund", "_mark"]) + how="inner", suffixes=["_mark", "_fund"]) if unavailable_pairs: raise OperationalException(