diff --git a/freqtrade/edge/__init__.py b/freqtrade/edge/__init__.py index 61cf6940e..c0df17909 100644 --- a/freqtrade/edge/__init__.py +++ b/freqtrade/edge/__init__.py @@ -152,10 +152,12 @@ class Edge(): def stoploss(self, pair: str) -> float: return self._cached_pairs[pair].stoploss - def filter(self, pairs) -> list: + def adjust(self, pairs) -> list: + """ + Filters out and sorts "pairs" according to Edge calculated pairs + """ final = [] - for pair, info in self._cached_pairs.items(): if info.expectancy > float(self.edge_config.get('minimum_expectancy', 0.2)) and \ info.winrate > float(self.edge_config.get('minimum_winrate', 0.60)) and \ @@ -163,10 +165,7 @@ class Edge(): final.append(pair) if final: - logger.info( - 'Edge validated only %s', - final - ) + logger.info('Edge validated only %s', final) else: logger.info('Edge removed all pairs as no pair with minimum expectancy was found !') diff --git a/freqtrade/freqtradebot.py b/freqtrade/freqtradebot.py index bff1b35ba..f82f6da59 100644 --- a/freqtrade/freqtradebot.py +++ b/freqtrade/freqtradebot.py @@ -408,7 +408,7 @@ class FreqtradeBot(object): # running get_signal on historical data fetched # to find buy signals if self.edge: - whitelist = self.edge.filter(whitelist) + whitelist = self.edge.adjust(whitelist) for _pair in whitelist: (buy, sell) = self.strategy.get_signal(_pair, interval, self.exchange.klines.get(_pair))