输入/搜索内容
0
关注
0
关注者
为什么模拟级和实盘级的回测结果不一样,设置的都是火币网的BTC_USDT,策略见帖子
帮助
创建于 2019-08-01 14:54:24  更新于 2019-08-01 15:19:30
 1
 2058
def CancelPendingOrders(): orders = _C(exchange.GetOrders) Log(len(orders)) for order in orders: exchange.CancelOrder(order.Id,order) def onTick(): depth = _C(exchange.GetDepth) askprice = depth.Asks[0].Price-0.01 bidprice = depth.Bids[0].Price+0.01 if bidprice<askprice: bidprice = askprice+0.01 CancelPendingOrders() exchange.Sell(askprice,30) exchange.Buy(bidprice,30) def main(): while (true): onTick() Sleep(2000)
相关推荐
评论
全部评论 (1)

    可以看下这个帖子: https://www.fmz.com/bbs-topic/662
    实盘级别回测 和 模拟级别回测 回测机制不同。

    7 年前
  • 1
社区
回测系统
APP 下载
iPhone 下载
© 2015 - ∞ INVENTOR PTE LTD (SG)