variable:n=0,m=0;
if 平多条件 and holding>0 then begin
sell......;
n:=0;
end
if 平空条件 and holding<0 then begin
sellshort......;
m:=0;
end
if 开空条件 then begin
n:=n+1;
m:=0;
end
if 开多条件 then begin
m:=m+1;
n:=0;
end
if typebar(1,2)<typebar(1,4) and n=开空条件成立次数 then buy().......;
if typebar(1,4)<typebar(1,2) and m=开多条件成立次数 then buyshort()......;
信号颜色是固定的,不同开多,信号箭头都是同一种颜色
区分是在信号前显示不同的字体,比如:
开多1:buy(c>o,1,market);
开多2:buy(c=o,1,market);
开多3:buy(c<o,1,market);
这样就能区分3种不同的开多了
f typebar(1,2)<typebar(1,4) and n=开空条件成立次数 then buy().......;
if typebar(1,4)<typebar(1,2) and m=开多条件成立次数 then buyshort()......;
请斑竹帮忙确认一下“n=开空条件成立次数 then buy().......;”---对照前面的应为开空还是开多?
谢谢