4月17日 我09:09卷賣2471x5
系統幫我於 09:17損出
我09:18 再一次卷賣 2471x5
系統於09:18自己幫我買15張 這樣真的挺恐怖。
4/22 類似的情況又發生了。 09:17:10 卷賣4977x1 09:17:14 卷賣4977x1 09:17:18 卷賣4977x1 截至目前庫存為-3 09:17:50 停損出 資買 直接買了6張............... 到底是哪有問題? 頭痛
虎大可以幫我看看 拜託!

//多單停損(%) input: profit_percent(5.0, "停利(%)"); input: loss_percent(1.2, "停損(%)"); if Position > 0 and Filled > 0 then begin { 依照成本價格設定停損/停利 } if profit_percent > 0 and Close >= FilledAvgPrice*(1+0.01*profit_percent) then begin { 停利 } SetPosition(0, label:="停利出場"); end else if loss_percent > 0 and Close <= FilledAvgPrice*(1-0.01*loss_percent) then begin { 停損 } SetPosition(0,getField("跌停價","D"), label:="停損出場"); end; end; //空單停損(%) if Position < 0 and Filled < 0 then begin { 依照成本價格設定停損/停利 } if profit_percent > 0 and Close <= FilledAvgPrice*(1-0.01*profit_percent) then begin { 停利 } SetPosition(0, label:="停利出場"); end else if loss_percent > 0 and Close >= FilledAvgPrice*(1+0.01*loss_percent) then begin { 停損 } SetPosition(0,getField("漲停價","D"), label:="停損出場"); end; end; if currentTime>=132500 and position>0 then setposition(0,getField("跌停價","D")); //多單平倉 if currentTime>=132500 and position<0 then setposition(0,getField("漲停價","D")); //空單平倉

14 評論