diff:=ema(close,12)-ema(close,26);dea:=ema(diff,9);macd:=2*(diff-dea);sx:=barslast(cross(dea,diff))+1;jx:=barslast(cross(diff,dea))+1;t1:=if(jx=1 and diff>ref(diff,ref(jx,1)+1),1,0);t2:=if(jx=1 and llv(diff,sx)>ref(llv(diff,sx),sx),1,0);xg:t1 or t2; 20210311
a1:=ma(c,5);a2:=ma(c,8);a3:=ma(c,13);a4:=ma(c,21);a5:=ma(c,60);a6:=c>a1 and c>a2 and c>a3 and c>a4 and c>a5;{今收盘在各均线之上}a7:=ref(l,2)>ref(h,3) and ref(l,1)>ref(h,3) and l>ref(h,3...