通达信新财富阶梯主图指标公式
2020/12/8 18:50:02
M:=30;
高1:=HHV(H,M);
低1:=LLV(L,M);
H1:=高1-(高1-低1)*0.191;
H2:=高1-(高1-低1)*0.382;
H3:=高1-(高1-低1)*0.5;
H4:=高1-(高1-低1)*0.618;
H5:=高1-(高1-低1)*0.809;
DRAWTEXT(高1 AND ISLASTBAR,高1,'----高');
DRAWTEXT(H1 AND ISLASTBAR,H1,'----0.191');
DRAWTEXT(H2 AND ISLASTBAR,H2,'----0.382');
DRAWTEXT(H3 AND ISLASTBAR,H3,'----0.500');
DRAWTEXT(H4 AND ISLASTBAR,H4,'----0.618');
DRAWTEXT(H5 AND ISLASTBAR,H5,'----0.809');
DRAWTEXT(低1 AND ISLASTBAR,低1,'----低');
突破:=REF(EMA(C,5),1);
A1X:=(EMA(C,2)-突破)/突破*100;
基准:=IF(A1X>=0,REF(EMA(C,2),BARSLAST(CROSS(A1X,0))+1),REF(EMA(C,2),BARSLAST(CROSS(0,A1X))+1));
STICKLINE(A1X>=0,基准,突破+0.001*C,4,0),COLORYELLOW;
STICKLINE(A1X<0,基准,突破-0.001*C,4,0),COLORGREEN;
STICKLINE(A1X>=0,基准,突破,3,1),COLOR000099;
STICKLINE(A1X<0,基准,突破,3,1),COLORLIGRAY;
DRAWKLINE(H,O,L,C);
高:=CONST(高1);
低:=CONST(低1);
H191:=CONST(H1);
H382:=CONST(H2);
H500:=CONST(H3);
H618:=CONST(H4);
H809:=CONST(H5);
IF(CURRBARSCOUNT<=10,高,DRAWNULL)COLORMAGENTA;
IF(CURRBARSCOUNT<=10,低,DRAWNULL)COLORWHITE;
IF(CURRBARSCOUNT<=10,H191,DRAWNULL)COLORRED,DOTLINE;
IF(CURRBARSCOUNT<=10,H382,DRAWNULL)COLORLIRED,DOTLINE;
IF(CURRBARSCOUNT<=10,H500,DRAWNULL)COLORYELLOW,DOTLINE;
IF(CURRBARSCOUNT<=10,H618,DRAWNULL)COLORLIBLUE,DOTLINE;
IF(CURRBARSCOUNT<=10,H809,DRAWNULL)COLORGREEN,DOTLINE;
DRAWICON(A1X>=0 AND REF(A1X,1)<0,L,11);
DRAWICON(A1X<0 AND REF(A1X,1)>=0,H,12);
投股 票网 www.tou1 8.cn
股市公式下载推荐