月K: KDJ.K (89,3,3),COLOR00FF00;
月D: KDJ.D (89,3,3),COLOR00FF00,LINETHICK2;
周K: KDJ.K (27,3,3),COLORRED;
周D: KDJ.D (27,3,3),COLORRED,LINETHICK2;
日K: KD.K (5,3,3),COLORWHITE;
日D: KD.D (5,3,3),COLORWHITE,LINETHICK2;
日金叉:IF(CROSS(日K,日D),50,0),COLORFFFFFF;
DRAWTEXT(日金叉,50,'日叉'),COLORFFFFFF;
周金叉:IF(CROSS(周K,周D),30,0),COLORRED;
DRAWTEXT(周金叉,30,'周叉'),COLORRED;
月金叉:IF(CROSS(月K,月D),20,0),COLOR0080FF;
DRAWTEXT(月金叉,20,'月叉'),COLORYELLOW;
{KD在30以下多次金叉}
JM:=CROSS( KDJ.K (5,3,3), KDJ.D (5,3,3));
JMCOUNT:=COUNT(JM,BARSLAST( KDJ.D (5,3,3) =30));
JMTJ:=28*( KDJ.D (5,3,3) 30 AND COUNT(JMCOUNT=1,21)=1);
DRAWTEXT (JMTJ,70,'①'),COLORWHITE;
JMTJ2:=28*( KDJ.D (5,3,3) 30 AND COUNT(JMCOUNT=2,21)=1);
DRAWTEXT (JMTJ2,70,'②'),COLORYELLOW;
JMTJ3:=28*( KDJ.D (5,3,3) 30 AND COUNT(JMCOUNT=3,21)=1);
DRAWTEXT (JMTJ3,70,'③'),COLORYELLOW;
JMTJ4:=28*( KDJ.D (5,3,3) 30 AND COUNT(JMCOUNT=4,21)=1);
DRAWTEXT (JMTJ4,70,'④'),COLORYELLOW;
JMTJ5:=28*( KDJ.D (5,3,3) 30 AND COUNT(JMCOUNT=5,21)=1);
DRAWTEXT (JMTJ5,70,'⑤'),COLORYELLOW;
预警公式
周K:= KDJ.K (27,3,3);
周D:= KDJ.D (27,3,3);
日K:= KD.K (5,3,3);
日D:= KD.D (5,3,3);
日金叉:=IF(CROSS(日K,日D),50,0);
周金叉:=IF(CROSS(周K,周D),30,0);
YUJ:=日金叉 OR 周金叉;
LB:=VOL/MA(REF(VOL,1),5);
XG:YUJ AND LB 2 AND V/CAPITAL*100 3 AND V/CAPITAL*100