【通达信】核心买卖主图指标公式
2015.11.08 21:00
DRAWGBK(O>C,RGB(0,30,0),RGB(0,0,60),0,’01’,0);
DRAWKLINE(H,O,L,C);
风险线:= MA(CLOSE,13);
止损线:= MA(CLOSE,27);
界:=MA(CLOSE,21);
DK:=MA(((SLOPE(C,5))+C),5);
STICKLINE(DK<=C AND CLOSE>=OPEN,HIGH,LOW,0.1,1),COLOR009AEE;
STICKLINE(DK<=C AND CLOSE>=OPEN,CLOSE,OPEN,2.8,1),COLOR009AEE;
STICKLINE(DK<=C AND CLOSESTICKLINE(DK<=C AND CLOSE STICKLINE(DK>C AND CLOSE>=OPEN,HIGH,LOW,0.1,1),COLOR7A7A7A;
STICKLINE(DK>C AND CLOSE>=OPEN,CLOSE,OPEN,2.8,1),COLOR7A7A7A;
STICKLINE(DK>C AND CLOSESTICKLINE(DK>C AND CLOSE DRAWTEXT(CROSS(C,DK),LOW*0.99,’★B’),COLORMAGENTA;
DRAWTEXT(CROSS(DK,C),H*1.01,’☆S’),COLORYELLOW;
DRAWTEXT(CROSS(MA(C,5),界),L*0.99,’◇底背离’),COLORWHITE;
DRAWTEXT(CROSS(C,止损线) AND 止损线>风险线,L*0.97,’主升浪’),COLORRED;
XX:=30;
高:=REFDATE(HHV(H,XX),DATE);
低:=REFDATE(LLV(L,XX),DATE);
H1:=高-(高-低)*0.191;
H2:=高-(高-低)*0.382;
H3:=高-(高-低)*0.5;
H4:=高-(高-低)*0.618;
H5:=高-(高-低)*0.809;
DRAWTEXT(CURRBARSCOUNT=1,高,’高位’),COLORRED;
DRAWTEXT(CURRBARSCOUNT=1,H1,’809′),COLORWHITE;
DRAWTEXT(CURRBARSCOUNT=1,H2,’618′),COLORRED;
DRAWTEXT(CURRBARSCOUNT=1,H3,’050′),COLORLIMAGENTA;
DRAWTEXT(CURRBARSCOUNT=1,H4,’382′),COLORRED;
DRAWTEXT(CURRBARSCOUNT=1,H5,’191′),COLORWHITE;
DRAWTEXT(CURRBARSCOUNT=1,低,’低位’),COLORRED;
STICKLINE(CURRBARSCOUNT=13,高,高,100,-1),COLORRED;
STICKLINE(CURRBARSCOUNT=13,H1,H1,100,-1),COLORWHITE;
STICKLINE(CURRBARSCOUNT=13,H2,H2,100,-1),COLORRED;
STICKLINE(CURRBARSCOUNT=13,H3,H3,100,-1),COLORLIMAGENTA;
STICKLINE(CURRBARSCOUNT=13,H4,H4,100,-1),COLORRED;
STICKLINE(CURRBARSCOUNT=13,H5,H5,100,-1),COLORWHITE;
STICKLINE(CURRBARSCOUNT=13,低,低,100,-1),COLORRED;
RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
J:=3*K-2*D;
MA5:=MA(CLOSE,5);
DIFF:=(EMA(J,8) – EMA(J,16));
DEA:=EMA(DIFF,5);
MACDG:=2*(DIFF-DEA);
卖:=CROSS((MA5REF(MA5,1) AND MACDG>REF(MACDG,1) AND J>REF(J,1)));
DRAWTEXT(FILTER(卖,5),H*1.05,’★卖’),COLOR00FF00;
STICKLINE(FILTER(卖,5),H*1.15,H,0,0),COLOR05FF00;
买:=CROSS((MA5>REF(MA5,1) AND MACDG>REF(MACDG,1) AND J>REF(J,1)),(MA5 DRAWTEXT(FILTER(买,5),L*0.98,’★买’),COLOR0000FF;
STICKLINE(FILTER(买,5),L*0.8,L,0,0),COLOR0555FF;
申明:本文为作者投稿或转载,在概念股网 http://www.gainiangu.com/ 上发表,为其独立观点。不代表本网立场,不代表本网赞同其观点,亦不对其真实性负责,投资决策请建立在独立思考之上。