Update backtesting.py

This commit is contained in:
Sam Germain 2022-02-05 18:29:48 -06:00 committed by GitHub
parent 8b57827676
commit e0d42ad9a7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -414,7 +414,6 @@ class Backtesting:
def _get_adjust_trade_entry_for_candle(self, trade: LocalTrade, row: Tuple def _get_adjust_trade_entry_for_candle(self, trade: LocalTrade, row: Tuple
) -> LocalTrade: ) -> LocalTrade:
# TODO: Write tests
current_profit = trade.calc_profit_ratio(row[OPEN_IDX]) current_profit = trade.calc_profit_ratio(row[OPEN_IDX])
min_stake = self.exchange.get_min_pair_stake_amount(trade.pair, row[OPEN_IDX], -0.1) min_stake = self.exchange.get_min_pair_stake_amount(trade.pair, row[OPEN_IDX], -0.1)
max_stake = self.exchange.get_max_pair_stake_amount(trade.pair, row[OPEN_IDX]) max_stake = self.exchange.get_max_pair_stake_amount(trade.pair, row[OPEN_IDX])