if then cross;
改成
a:=cross;
if then a;
input:n(13,1,20,1);
input:m(70,-200,200,1);
//交易手数:
tn:=1;
r1:=barslast(day-ref(day,1)<>0);
r5:ref(o,r1)+0.1*m;
r6:r5+n;
r7:r5-n;
if time>091500 and time<150000 then
begin
a:=cross;
if a(h,r6) then
begin
buy(holding=0,tn,limitr,r6);
end
if a(r7,l) then
begin
buyshort(holding=0,tn,limitr,r7);
end
if holding>0 and a(r5,l) then
begin
sell(1,0,limitr,r5);
end
if holding<0 and a(h,r5) then
begin
sellshort(1,0,limitr,r5);
end
end
//收盘前清仓
if time>=151000 then
begin
s
我简写了,
具体是
a:=cross(需要上穿的内容看函数说明编写)