From db942321ad7ce714211ce98eb19af2dcfe015aef Mon Sep 17 00:00:00 2001 From: robcaulk Date: Thu, 3 Nov 2022 21:03:48 +0100 Subject: [PATCH] fix bug with lightgbm and colons --- freqtrade/freqai/data_kitchen.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/freqtrade/freqai/data_kitchen.py b/freqtrade/freqai/data_kitchen.py index 77e825d27..6acd916d5 100644 --- a/freqtrade/freqai/data_kitchen.py +++ b/freqtrade/freqai/data_kitchen.py @@ -1153,12 +1153,13 @@ class FreqaiDataKitchen: pairs = self.freqai_config["feature_parameters"].get("include_corr_pairlist", []) for pair in pairs: + pair = pair.replace(':', '') # lightgbm doesnt like colons valid_strs = [f"%-{pair}", f"%{pair}", f"%_{pair}"] pair_cols = [col for col in dataframe.columns if any(substr in col for substr in valid_strs)] if pair_cols: pair_cols.insert(0, 'date') - corr_dataframes[pair] = dataframe.filter(pair_cols, axis=1) + corr_dataframes[pair] = dataframe.filter(pair_cols, axis=1) return corr_dataframes