买线:=EMA(C,2);
卖线:=EMA(SLOPE(C,21)*20+C,42);
STICKLINE(买线>=卖线,REFDATE(HHV(H,0),DATE),REFDATE(LLV(L,0),DATE),6,0),COLOREE6600;
STICKLINE(买线<卖线,REFDATE(HHV(H,0),DATE),REFDATE(LLV(L,0),DATE),6,0),COLOR404050;
DRAWKLINE(H,O,L,C);
指导:=EMA((EMA(CLOSE,4)+EMA(CLOSE,6)+EMA(CLOSE,12)+EMA(CLOSE,24))/4,2);
界:=MA(CLOSE,27);
B买:IF(CROSS(指导,界) OR CROSS(买线,卖线),C,DRAWNULL),COLORBLUE,NODRAW;
持仓:IF(买线>=卖线,C,DRAWNULL),COLORRED,NODRAW;
S卖:IF(CROSS(界,指导) OR CROSS(卖线,买线),C,DRAWNULL),COLORLIGRAY,NODRAW;
空仓:IF(买线<卖线,C,DRAWNULL),COLORGREEN,NODRAW;
突破:=REF(EMA(C,14),1);
A1X:=(EMA(C,10)-突破)/突破*100;
多方:=IF(A1X>=0,REF(EMA(C,10),BARSLAST(CROSS(A1X,0))+1),DRAWNULL);
空方:=IF(A1X<0,REF(EMA(C,10),BARSLAST(CROSS(0,A1X))+1),DRAWNULL);
STICKLINE(A1X<0,空方,突破,10,0),COLOR00CC66;
STICKLINE(A1X>=0,多方,突破,10,0),COLOR000099;
DRAWICON(CROSS(买线,卖线),L,1);
DRAWICON(CROSS(卖线,买线),H,2);
BU:=CROSS(HIGH,SAR(3,1,20));
SEL:=CROSS(SAR(3,1,20),LOW);
DRAWTEXT(BU,LOW,'B'),COLORYELLOW,LINETHICK2;
DRAWTEXT(SEL,1.01*HIGH,'S'),COLORGREEN,LINETHICK2;
{股票指标网 整理};