IF HOLDING<0 and CROSS(MA5,MA10) THEN
SELLSHORT(1,HOLDING,LIMITR,CLOSE);
这个再加上什么?或者用其它什么代码比较好
5日线上穿10日,并且5日线小于20 日线 或40 日线
if cross(ma(c,5),ma(c,10)) and ((ma(c,5)<ma(c,20) ) or (ma(c,5)<ma(c,40))) then sell(1,0,,thisclose);
用thisclose 和close区别不大吧
if 条件a then 平仓a:sell(1,0,,thisclose);
if 条件b then 平仓b:sell(1,0,,thisclose);
if 条件c then 平仓c:sell(1,0,,thisclose);
类似这样的写法,在k线图上会显示对应的“平仓a”“平仓b”“平仓c”
不行,还是不会写 先帮我改写这个,我看看
IF (HOLDING=0) THEN BEGIN
IF TMP<=0&&TMP2 THEN
BUY(1,1,LIMITR,CLOSE);
end
IF (HOLDING=0) THEN BEGIN
IF TMP<=0&&TMP2 THEN
开仓a:BUY(1,1,LIMITR,CLOSE);
end