买卖分别一次还是买卖加起来一次
variable:bj_buy=0;
varialbe:bj_sell=0;
if 开仓条件 and holdng=0 and bj_buy=0 then begin
buy(1,1,marketr);
bj_buy:=1;
end
if 平仓条件 and holding>0 and bj_sell=0 then begin
sell(1,0,marketr);
bj_sell:=1;
end
if time=closetime(0) then begin
bj_buy:=0;
bj_sell:=0;
end