以下是通达信超级中期方向线副图指标

N:=20;
 { N 1 300 20}
 EMA5:=EXPMA(C,5);
 EMA30:=EXPMA(C,30);
 A1:EMA5-EMA30;
中期方向线:A1,LINETHICK;

DRAWBAND(中期方向线,RGB(190,0,0),0,RGB(0,190,0));
 {DRAWBAND}(中期方向线,RGB(190,0,0),0,RGB(0,190,0));
 MB:=EMA(中期方向线,N);

超买线:MB+1.0*STD(A1,20)COLORYELLOW,LINETHICK2;
超卖线:MB-1.0*STD(A1,20)COLORCYAN,LINETHICK2;

中轴方向线:MB,LINETHICK1;

STICKLINE(A1>0 AND A1>=REF(A1,1),0,A1,1,0),COLOR0000FF,COLORRED;
 STICKLINE(A1>0 AND A1<=REF(A1,1),0,A1,0,0),COLOR000066,COLORRED;
 STICKLINE(A1<0 AND A1<REF(A1,1),0,A1,0,0),COLOR00CC33,COLORCYAN;
 STICKLINE(A1<0 AND A1>=REF(A1,1),0,A1,1,0),COLOR006633,COLORCYAN;

上穿上限1:IF(CROSS(A1,超买线),3,0)COLORRED;
下穿上限1:IF(CROSS(超买线,A1),-3,0)COLORRED;
上穿下限2:IF(CROSS(A1,超卖线),3,0)COLORMAGENTA;
下穿下限2:IF(CROSS(超卖线,A1),-3,0)COLORMAGENTA;

 DRAWTEXT_FIX(1,0.00,0.08,0,’所属行业’)COLORYELLOW;
 DRAWTEXT_FIX(1,0.06,0.08,0,HYBLOCK)COLORYELLOW;
 DRAWTEXT_FIX(1,0.20,0.08,0,’所属地区’)COLORYELLOW;
 DRAWTEXT_FIX(1,0.26,0.08,0,DYBLOCK)COLORYELLOW;

声明:本站所有文章,如无特殊说明或标注,均为本站原创发布。任何个人或组织,在未征得本站同意时,禁止复制、盗用、采集、发布本站内容到任何网站、书籍等各类媒体平台。如若本站内容侵犯了原著者的合法权益,可联系我们进行处理。