寫了一段出場警示,
內容是漲超過一個%數就出場,如果沒有就是在13:23:30~13:24:30出場,
觸發條件為1分鐘K,連續觸發(選擇單次觸發或是時間內只觸發一次,在%數警示時會太慢或漏掉)
實際跑的結果會從13:23:59 一路警示到 13:24:59,
並不會在13:24:30 停止,這是合理的嗎?
input: o1(132330,"出1");
input: o2(132430,"出2");
input: r1(7,"風控");
if
c>getfield("參考價", "D")*(1+0.01*r1)
then ret=1
else if
o1<=time and time<=o2
then ret=1;

1 評論