Type/to search

Robot Stop Loss Harga Tetap Sederhana

Study
3
Follow
1503
Followers

Sebuah robot stop loss dengan harga tetap yang sederhana dapat membantu Anda menghentikan kerugian.

Parameter:

StopPrice:Fixed price to stop loss

Intervel: Intervel(second) of checking coin price

Source
JavaScript
function CancelPendingOrders() {
    var orders = _C(exchange.GetOrders);
    for (var j = 0; j < orders.length; j++) {
        exchange.CancelOrder(orders[j].Id, orders[j]);
    }
}
function StopLoss(){
    var done = false
    while(!done){
        var ticker = _C(exchange.GetTicker)
        account = _C(exchange.GetAccount)
        var price = ticker.Buy
Strategy parameters
Strategy parameters
Fixed price to stop loss
Intervel(second) of checking coin price
Comment
All comments (3)

    是不是把自己的单子挂出去,有可能你的挂单卖家已经大于实时价格了,那么你这个单子就不会成交,所以立即取消掉,重新检测最新卖价,重新用最新卖家挂单

    5 years ago

    有的疑问,为什么卖出后,立即要再去取消这个卖出单那?是为了防止什么情况:
    var id = exchange.Sell(price, amount);
    if(id){
    exchange.CancelOrder(id)
    }

    6 years ago

    是不是把自己的单子挂出去,有可能你的挂单卖家已经大于实时价格了,那么你这个单子就不会成交,所以立即取消掉,重新检测最新卖价,重新用最新卖家挂单

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