(以下是通达信分时主图指标源码)
[color=]{参数 N,最小1,最大100,缺省20}
X_1:=CLOSE;
X_2:=ZSTJJ;
X_3:=REF(CLOSE,1);
X_4:=SMA(MAX(CLOSE-X_3,0),14,1)/SMA(ABS(CLOSE-X_3),14,1)*100;
X_5:=CROSS(80,X_4);
X_6:=FILTER(X_5,40) AND CLOSE/X_2>1.03;
DRAWICON(X_6,REF(CLOSE*1.01,1),41);
X_7:=CROSS(X_4,20);
X_8:=FILTER(X_7,40) AND CLOSE/X_2
DRAWICON(X_8,CLOSE*0.997,38);
X_9:=CLOSE>REF(CLOSE,1) AND CLOSE/X_2>1+N/1000;
X_10:=CLOSE
X_11:=CROSS(SUM(X_9,0),0.5);
X_12:=CROSS(SUM(X_10,0),0.5);
X_13:=SUM(X_11,0)*CROSS(COUNT(CLOSE
X_14:=SUM(X_12,0)*CROSS(COUNT(CLOSE>REF(CLOSE,1),BARSLAST(X_12)),0.5);
X1:CONST(SUM(IF(X_13,REF(CLOSE,1),DRAWNULL),0)),DOTLINE,COLORYELLOW;
Z1:CONST(SUM(IF(X_14,REF(CLOSE,1),DRAWNULL),0)),DOTLINE,COLORGREEN;
X_15:=CROSS(SUM(X_9 AND CLOSE>X1*(1+2/100),0),0.5);
X_16:=CROSS(SUM(X_10 AND CLOSE
X_17:=SUM(X_15,0)*CROSS(COUNT(CLOSE
X_18:=SUM(X_16,0)*CROSS(COUNT(CLOSE>REF(CLOSE,1),BARSLAST(X_16)),0.5);
X2:CONST(SUM(IF(X_17,REF(CLOSE,1),DRAWNULL),0)),COLORYELLOW;
Z2:CONST(SUM(IF(X_18,REF(CLOSE,1),DRAWNULL),0)),COLORGREEN;
DRAWICON(X_14,REF(CLOSE*0.995,1),1);
DRAWICON(X_18,REF(CLOSE*0.995,1),34);
DRAWICON(X_13,REF(CLOSE*1.003,1),2);
DRAWICON(X_17,REF(CLOSE*1.002,1),35);
X_19:=CLOSE>REF(CLOSE,1) AND CLOSE>X_2*(1+3/100);
X_20:=CLOSE
X_21:=CROSS(SUM(X_19,0),0.5);
X_22:=CROSS(SUM(X_20,0),0.5);
X_23:=SUM(X_21,0)*CROSS(COUNT(CLOSE
X_24:=SUM(X_22,0)*CROSS(COUNT(CLOSE>REF(CLOSE,1),BARSLAST(X_22)),0.5);
X_25:=CONST(SUM(IF(X_23,REF(CLOSE,1),DRAWNULL),0));
X_26:=CONST(SUM(IF(X_24,REF(CLOSE,1),DRAWNULL),0));
X_27:=CROSS(SUM(X_19 AND CLOSE>X_25*(1+3/100),0),0.5);
X_28:=CROSS(SUM(X_20 AND CLOSE
X_29:=SUM(X_27,0)*CROSS(COUNT(CLOSE
X_30:=SUM(X_28,0)*CROSS(COUNT(CLOSE>REF(CLOSE,1),BARSLAST(X_28)),0.5);
DRAWICON(X_29,CLOSE*1.003,27);
DRAWICON(X_30,CLOSE*0.993,26);
【以下是通达信分时主图效果图】:(备注:大智慧图标比较少不能一一对应通达信的,可用其它图标或文字代替)
[img][/img]