以下是大智慧分时里把DDX与VOL挂在一起比较源码

把VOL与DDX>0,DDX<0,DDX=0用不同颜色区分开,可以看清该成交量与DDX的比较
DRAWRECTREL(-1,0,1000,1000,RGB(0,20,0)),color00FF00,LINETHICK2,LAYER7;;0,DOTLINE;
 vul,STICK,colorff0099,linethick3;;;
 DDX:(ORDERVOL(1,2)-ORDERVOL(2,2)),LINETHICK0;
 S大单:SUM(DDX,0),COLOR0000FF,LINETHICK2,LAYER1;
 STICKLINE(DDX>0,0,DDX,4,0),COLOR0000ff,LINETHICK2,LAYER1; {DDX>0}
 STICKLINE(DDX<0,DDX,0,4,0),COLOR00ff00,LINETHICK2,LAYER1; {DDX<0}
 STICKLINE(DDX=0,-V,0,1,0),COLOR00FFFF,LINETHICK2,LAYER1; {DDX=0}
 S特大单:SUM((ORDERVOL(1,3)-ORDERVOL(2,3)),0),COLORff9900,LINETHICK3,LAYER1;
 drawtextabs(400,0,’大单差(>10W)与VOL’),COLOR00ffFF,LINETHICK4;
 VERTLINE(BARSTATUS=2,2),COLOR0077FF,LAYER0;
 {横柱图: 龙虎看盘}
TS2:=sum(ordervul(2,3)*100,0);
 DS2:=sum((ordervul(2,2)-ordervul(2,3))*100,0);
 ZS2:=sum((ordervul(2,1)-ordervul(2,2))*100,0);
 {SS2:=sum((1-ordervul(2,1))*100,0);}
 TB2:=sum(ordervul(1,3)*100,0);
 DB2:=sum((ordervul(1,2)-ordervul(1,3))*100,0);
 ZB2:=sum((ordervul(1,1)-ordervul(1,2))*100,0);
 {SB2:=sum((1-ordervul(1,1))*100,0);}
 ZLB:=(TB2+DB2);
 ZLS:=(TS2+DS2);
 ZLH:=ZLB+ZLS;
 ZLB1:=ZLB/ZLH;
 ZLS1:=ZLS/ZLH;
买卖比:ZLB/ZLS;
 DRAWRECTABS(70+ZLS1*100,2,70+(ZLS1+ZLB1)/2*100,40,RGB(255,0,255)),COLOR005500,LAYER0;
 DRAWRECTABS(70,11,70+ZLS1*100,28,RGB(0,55,0)),COLOR005500,LAYER0;
 DRAWRECTABS(70,13,70+ZLS1*100,26,RGB(0,150,0)),COLOR00BB00,LAYER0;
 DRAWRECTABS(70,14,70+ZLS1*100,25,RGB(0,255,0)),COLOR00FF00,LAYER0;
 DRAWRECTABS(70+ZLS1*100,11,70+(ZLS1+ZLB1)*100,28,RGB(55,0,0)),COLOR000055,LAYER0;
 DRAWRECTABS(70+ZLS1*100,13,70+(ZLS1+ZLB1)*100,26,RGB(150,0,0)),COLOR0000BB,LAYER0;
 DRAWRECTABS(70+ZLS1*100,14,70+(ZLS1+ZLB1)*100,25,RGB(255,0,0)),COLOR0000FF,LAYER0;
 DRAWTEXTABS(30,30,’DDX[卖:买] ‘+numtostrn(ZLS1*100,1)+’:’+NUMTOSTRN(ZLB1*100,1) ),color00FFFF,LINETHICK4,LAYER0;

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