diff --git a/v2realbot/ENTRY_backtest_strategyVykladaci.py b/v2realbot/ENTRY_backtest_strategyVykladaci.py index cdbd707..6972718 100644 --- a/v2realbot/ENTRY_backtest_strategyVykladaci.py +++ b/v2realbot/ENTRY_backtest_strategyVykladaci.py @@ -311,7 +311,7 @@ def next(data, state: StrategyState): #HLAVNI ITERACNI LOG JESTE PRED AKCI - obsahuje aktualni hodnoty vetsiny parametru lp = state.interface.get_last_price(symbol=state.symbol) - state.ilog(e="ENTRY", msg="AVGP:"+str(round(state.avgp,2))+ "POS:" +str(state.positions)+" PROFIT:"+str(round(state.profit,2)), last_price=lp, stratvars=state.vars) + state.ilog(e="ENTRY", msg="AVGP:"+str(round(float(state.avgp),2))+ "POS:" +str(state.positions)+" PROFIT:"+str(round(float(state.profit),2)), last_price=lp, stratvars=state.vars) #maxSlopeMA = -0.03 #SLOPE ANGLE PROTECTIONs diff --git a/v2realbot/strategy/StrategyOrderLimitVykladaci.py b/v2realbot/strategy/StrategyOrderLimitVykladaci.py index fc387ba..411d781 100644 --- a/v2realbot/strategy/StrategyOrderLimitVykladaci.py +++ b/v2realbot/strategy/StrategyOrderLimitVykladaci.py @@ -77,7 +77,7 @@ class StrategyOrderLimitVykladaci(Strategy): avg_costs = float(self.state.avgp) * float(data.qty) trade_profit = (sold_amount - avg_costs) self.state.profit += trade_profit - self.state.ilog(e="SELL not - PROFIT: "+str(round(trade_profit,3))+" celkem: "+str(round(self.state.profit,3)), msg=str(data.event), sold_amount=sold_amount, avg_costs=avg_costs, trade_qty=data.qty, trade_price=data.price, orderid=str(data.order.id)) + self.state.ilog(e="SELL not - PROFIT: "+str(round(float(trade_profit),3))+" celkem: "+str(round(float(self.state.profit),3)), msg=str(data.event), sold_amount=sold_amount, avg_costs=avg_costs, trade_qty=data.qty, trade_price=data.price, orderid=str(data.order.id)) if data.event == TradeEvent.PARTIAL_FILL: self.state.ilog(e="SELL notifikace - Partial fill", msg="pouze update pozic", orderid=str(data.order.id))