一根k线突破昨日最高点(开多平空),突破昨日最低点(开空平多);怎么编写?
LastH:CALLSTOCK('',vtHIGH,6,-1);
lastL:CALLSTOCK('',vtLOW,6,-1);
if cross(c,lastH) then
begin
SELLSHORT(holding<0,holding,market);
buy(holding=0,1,market);
END
if cross(lastL,l) then
begin
SELL(holding>0,holding,market);
BUYSHORT(holding=0,1,market);
END