DIFF:=EMA(CLOSE,12)-EMA(CLOSE,26);
DEA:=EMA(DIFF,9);
MACD:=2*(DIFF-DEA),LINETHICK0;
A1:=DIFF<0 AND DEA<0;
A2:=A1>REF(A1,1);
A3:=BArslAst(A2);
A4:=COUNT(DEA>0 AND DIFF>0,A3)=0;
A5:=CROSS(DIFF,DEA);{金叉}
A6:=BARSLAST(A5);
A7:=REF(A6,A6+1)+A6;
A8:=(DIFF+DEA)/2;
A9:=(HIGH+LOW)/2;
A10:=A5 AND A7<A3 AND A4 AND A8>REF(A8,A7) AND A9<REF(A9,A7) AND macd>0;
金叉介入:A10;