修复回测bug
This commit is contained in:
@@ -157,6 +157,7 @@ class SimpleLimitBuyStrategy(Strategy):
|
||||
self.log(f"[{current_datetime}] 开多仓信号 - 当前Open={bar.open:.2f}, "
|
||||
f"前1Range={range_1_ago:.2f}, 前7Range={range_7_ago:.2f}, "
|
||||
f"计算目标买入价={target_buy_price:.2f}")
|
||||
self.log(f'{self.context._simulator.get_current_positions()}')
|
||||
|
||||
order_id = f"{self.symbol}_BUY_{bar.datetime.strftime('%Y%m%d%H%M%S')}_{self.order_id_counter}"
|
||||
self.order_id_counter += 1
|
||||
|
||||
Reference in New Issue
Block a user