Type/to search

抢盘口做市策略 - 对敲

6
Follow
942
Followers

抢盘口做市策略, 最基础的做市策略,买一卖一抢单抢盘口, 赚买一卖一的差价.

Source
JavaScript

function CancelPendingOrders(orderType) {
    while (true) {
        var orders = _C(exchange.GetOrders);
        var count = 0;
        if (typeof(orderType) != 'undefined') {
            for (var i = 0; i < orders.length; i++) {
                if (orders[i].Type == orderType) {
                    count++;
                }
            }
        } else {
Strategy parameters
Strategy parameters
出错重试间隔(毫秒)
轮询间隔(秒)
滑点
盘口最小差价
手数
最小交易量
Comment
All comments (4)

    怎么确定币种呢?

    7 years ago

    感谢分享,尽量在读,有些地方还是不太懂,做了些注释,谢谢分享。 img img img

    8 years ago

    感谢注释

    7 years ago

    if (orders.length == 0 || orders[0].Type == ORDER_TYPE_SELL) {
    请问为什么需要对这个 orders[0].Type == ORDER_TYPE_SELL)进行判断啊?

    8 years ago
  • 1
iPhone Download
Forums
PINE Language
© 2015 - ∞ INVENTOR PTE LTD (SG)