ma5:MA(CLOSE,5),COLORFFFFFF;
MA10:MA(CLOSE,10),COLOR00FFFF;
MA21:MA (CLOSE,21),COLOR00FF00;
MA30:MA(CLOSE,30),COLOR0000FF;
买线:=ema (C,2);
卖线:=EMA(SLOPE(C,21)*20+C,42);
BUY1:=crOSS(买线,卖线);
SEL:=CROSS(卖线,买线);DRAWTEXT(BUY1,LOW*0.95,'B'),COLORRED,LINETHICK5;
DRAWTEXT (SEL,HIGH*1.05,'S'),COLORRED,LINETHICK5;
STICKLINE(买线>=卖线,LOW,HIGH,0.1,0),COLORBLUE;
STICKLINE(买线>=卖线,CLOSE,OPEN,3,3),COLORBLUE;
STICKLINE(买线<卖线,CLOSE,OPEN,3,3),COLORCYAN;
STICKLINE(买线<卖线,LOW,HIGH,0.1,0),COLORCYAN;
STICKLINE(CROSS(买线,卖线) OR CROSS(卖线,买线),OPEN,CLOSE,2.5,0),COLORRED;