vars:Kbar(0);
//當今天不等於昨天,就是開盤了..這時候把barnumber 丟給value1
IF date<>date[1] then begin
value1=barnumber;
END;
// 接下來盤開始跑,k線每完成一支都會有一個barnumber,我們再把每一根的barnumber
// 減掉開盤那一根的.(加1,是因為這樣減下去第一根會是0)
Kbar=barnumber-value1+1;
抱歉~~一直麻煩您
vars:kbar(0),Value1(0),Value2(0),Value3(0),Value4(0),Value5(0);
IF date<>date[1] then begin
value1=barnumber;
END;
if kbar=barnumber-value1+1 then ;
Value2=Minlist(kbar,30);
value3= Highest(high,Value2);
value4= lowest(low,Value2);
if marketposition = 0 and time>=0845 and time <=1315 then begin
if value3 < value3[1] and value4 > value4[1] then
buy next bar at market;