通达信定海神针 副图 选股源码

{副图}
n:=100;
 A1:=(EMA(CLOSE,12)-EMA(CLOSE,26))*100;A2:=EMA(A1,9);
 XG:=CROSS(A1,A2) AND A2<=-N;
 DRAWTEXT(XG,0.4,' 定'),COLORLIGRAY;DRAWTEXT(XG,0.3,' 海'),,COLORLIGRAY;
 DRAWTEXT(XG,0.2,' 神'),COLORLIGRAY;DRAWTEXT(XG,0.1,' 针'),,COLORLIGRAY;
 STICKLINE(XG,0,0.5,1.5,0),COLORYELLOW;
 STICKLINE(XG,0.4,0.5,1.5,0),COLORRED;
 STICKLINE(XG,0,0.1,1.5,0),COLORRED

{选股}
n:=100;
 A1:=(EMA(CLOSE,12)-EMA(CLOSE,26))*100;A2:=EMA(A1,9);
 XG:CROSS(A1,A2) AND A2<=-N;