if time>=145500 and time<050000 then begin
sell(1,0,marketr);
sellshort(1,0,marketr);
end
既要大于145500,又要小于050000的,是没有的。你的条件恒不成立
比如铜,我想他下午收盘前5分钟平仓,夜盘也提前5分钟平仓,该怎么写,老师
if (time>=145500 and time<150000) or (time>=045500 and time<050000) then begin
sell(1,0,marketr);
sellshort(1,0,marketr);
end
你夜盘是只有到1点是吧?那为什么你前面要写是5点?
time>=045500 and time<050000) 改成
time>=005500 and time<010000)
JINZHE老师,
我引用了您这个语句,在5分钟级别也没有强平信号,是不是逐K的矛盾,要改提前10分钟才检测得到?