exchange.GetPosition (() 는 무수함수인지 아닌지를 판단하기 위해 주의를 사용합니다.

저자:, 2018-11-07 08:17:28, 업데이트: 2019-04-17 15:52:12

    exchange.SetTimeout(3000);
    exchange.SetContractType("XBTUSD");

    //取得第一次币量
    position = _C(exchange.GetPosition);
    last_Amount = position[0].Amount; //持币数量  
    hold_price = Math.round(position[0].Price); //持币均价
    
    
    TypeError: cannot read property 'Amount' of undefined at main (__FILE__:38)

관련

더 많은

var position = _C (exchange.GetPosition); log (("포지션, 위치"의 실제 내용); var len = position.length; //변수 길이를 로그 (Length of array, len) 그래서 len: 빈칸은 0이고, 빈칸은 1입니다. 이 수직선에서 1을 빼면 감사합니다.

작은 꿈GetPosition는 포지션 행렬을 반환합니다. 포지션 행렬이 없으면 []를 반환합니다. 포지션 행렬이 없으면 빈 행렬입니다. 포지션 행렬이 없으면 포지션 행렬을 호출합니다. 이것은 당신의 전략 프로그램이 처리하지 못한 것입니다.