资金监控庄家和私募和主力的优化主图 源码 再次优化
非大宗进:=(中B)+(小B);
非大宗出:=(中S)+(小S);
主力买力度:=LARGEINTRDVOL*100/VOL,NODRAW;
主力卖力度:=LARGEOUTTRDVOL*100/VOL,NODRAW;
AA:=CONST(MAX(ABS(净流入),MAX(ABS(大宗净流入),MAX(ABS(大宗进),MAX(ABS(大宗出),MAX(ABS(非大宗进),ABS(非大宗出)))))))*3,NODRAW;
DRAWRECTREL(0,CONST(855-(ABS(大宗进)*500/AA)),38,965,IF(CONST(大宗进)>0,RGB(255,0,0),RGB(23,125,255)));
DRAWRECTREL(45,CONST(855-(ABS(大宗出)*500/AA)),83,965,IF(CONST(大宗出)<0,RGB(0,50,0),RGB(0,50,0)));
DRAWRECTREL(100,CONST(855-(ABS(非大宗进)*500/AA)),140,965,IF(CONST(非大宗进)>0,RGB(255,0,0),RGB(23,125,255)));
DRAWRECTREL(150,CONST(855-(ABS(非大宗出)*500/AA)),189,965,IF(CONST(非大宗出)<0,RGB(0,50,0),RGB(0,50,0)));
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.00,1,0,' 进 主力 出 进 散户 出'),COLORWHITE;
DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.005,0.88,0,INTPART(大宗进)),COLORWHITE;
DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.043,0.88,0,INTPART(大宗出)),COLORWHITE;
DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.102,0.88,0,INTPART(非大宗进)),COLORWHITE;
DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.156,0.88,0,INTPART(非大宗出)),COLORWHITE;
主买A:=ACTINVOL,COLORRED,NODRAW;
主卖A:=ACTOUTVOL,COLORGREEN,NODRAW;
主买:主买A*100/(主买A+主卖A),NODRAW,COLORRED;
主卖:主卖A*100/(主买A+主卖A),NODRAW,COLORGREEN;
DRAWRECTREL(0,620,194,675,RGB(0,75,200));
DRAWRECTREL(0,620,194,675,RGB(0,250,50));
DRAWRECTREL(0,620,80+CONST(主买*160/100),675,RGB(175,50,250));
DRAWTEXT_FIX(1,0.00,0.63,0,STRCAT(STRCAT('主动买卖比 ',CON2STR(主买,2)),' %')),COLORYELLOW;
DRAWTEXT_FIX(1,0.14,0.63,0,STRCAT(STRCAT(' ',CON2STR(主卖,2)),' %')),COLORYELLOW;
DRAWRECTREL(0,730,194,680,RGB(0,75,200));
DRAWRECTREL(0,730,194,680,RGB(0,250,50));
DRAWRECTREL(0,730,80+CONST(主力买力度*160/100),680,RGB(200,0,50));
DRAWTEXT_FIX(1,0.00,0.69,0,STRCAT(STRCAT('主动买卖力 ',CON2STR(主力买力度,2)),'%')),COLORYELLOW;
DRAWTEXT_FIX(1,0.14,0.69,0,STRCAT(STRCAT(' ',CON2STR(主力卖力度,2)),'%')),COLORYELLOW;
DDX:=(LARGEINTRDVOL-LARGEOUTTRDVOL)*100000/FINANCE(7),NODRAW;
DDY:=IF(TRADENUM>0,(TRADEOUTNUM-TRADEINNUM)*100/TRADENUM,0);
DDZ:=IF(TRADENUM>0,(LARGETRDINNUM-LARGETRDOUTNUM)/TRADENUM*100,0);
DRAWRECTREL(197,620,250,660,IF(CONST(DDX)>0,RGB(255,0,0),RGB(0,50,0)));
DRAWRECTREL(197,665,250,700,IF(CONST(DDX)>0,RGB(255,0,0),RGB(0,50,0)));
DRAWRECTREL(197,738,250,792,IF(CONST(DDY)>0,RGB(255,0,0),RGB(0,50,0)));
DRAWRECTREL(197,782,250,822,IF(CONST(DDY)>0,RGB(255,0,0),RGB(0,50,0)));
DRAWRECTREL(197,872,250,912,IF(CONST(DDZ)>0,RGB(255,0,0),RGB(0,50,0)));
DRAWRECTREL(197,918,250,962,IF(CONST(DDZ)>0,RGB(255,0,0),RGB(0,50,0)));
DRAWTEXT_FIX(1,0.20,0.62,0,STRCAT('',CON2STR(DDX,3))),COLORYELLOW;
DRAWTEXT_FIX(1,0.20,0.74,0,STRCAT('',CON2STR(DDY,3))),COLORYELLOW;
DRAWTEXT_FIX(1,0.20,0.87,0,STRCAT('',CON2STR(DDZ,3))),COLORYELLOW;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.20,0.70,0,'大单动向'),COLORWHITE;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.20,0.83,0,'涨跌动因'),COLORWHITE;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.20,0.98,0,'大单差分'),COLORWHITE;
T1:=IF (DDX>0 AND REF(DDX,1)<0,1,0);
T2:=IF (DDX>0 AND REF(DDX,1)>0 AND REF(DDX,2)<0,2,T1);
T3:=IF (DDX>0 AND REF(DDX,1)>0 AND REF(DDX,2)>0 AND REF(DDX,3)<0,3,T2);
T4:=IF (DDX>0 AND REF(DDX,1)>0 AND REF(DDX,2)>0 AND REF(DDX,3)>0 AND REF(DDX,4)<0,4,T3);
T5:=IF (DDX>0 AND REF(DDX,1)>0 AND REF(DDX,2)>0 AND REF(DDX,3)>0 AND REF(DDX,4)>0 AND REF(DDX,5)<0,5,T4);
T6:=IF (DDX>0 AND REF(DDX,1)>0 AND REF(DDX,2)>0 AND REF(DDX,3)>0 AND REF(DDX,4)>0 AND REF(DDX,5)>0 AND REF(DDX,6)<0,6,T5);
T7:=IF (DDX>0 AND REF(DDX,1)>0 AND REF(DDX,2)>0 AND REF(DDX,3)>0 AND REF(DDX,4)>0 AND REF(DDX,5)>0 AND REF(DDX,6)>0 AND REF(DDX,7)<0,7,T6);
T8:=IF (DDX>0 AND REF(DDX,1)>0 AND REF(DDX,2)>0 AND REF(DDX,3)>0 AND REF(DDX,4)>0 AND REF(DDX,5)>0 AND REF(DDX,6)>0 AND REF(DDX,7)>0 AND REF(DDX,8)<0,8,T7);
T9:=IF (DDX>0 AND REF(DDX,1)>0 AND REF(DDX,2)>0 AND REF(DDX,3)>0 AND REF(DDX,4)>0 AND REF(DDX,5)>0 AND REF(DDX,6)>0 AND REF(DDX,7)>0 AND REF(DDX,8)>0 AND REF(DDX,9)<0,9,T8);
T:=IF (DDX>0 AND REF(DDX,1)>0 AND REF(DDX,2)>0 AND REF(DDX,3)>0 AND REF(DDX,4)>0 AND REF(DDX,5)>0 AND REF(DDX,6)>0 AND REF(DDX,7)>0 AND REF(DDX,8)>0 AND REF(DDX,9)>0,10,T9);
DRAWTEXT_FIX(1,0.20,0.66,0,STRCAT(STRCAT(' ',CON2STR(T,0)),' [天] ')),COLORYELLOW;
T11:=IF (DDY>0 AND REF(DDY,1)<0,1,0);
T21:=IF (DDY>0 AND REF(DDY,1)>0 AND REF(DDY,2)<0,2,T11);
T31:=IF (DDY>0 AND REF(DDY,1)>0 AND REF(DDY,2)>0 AND REF(DDY,3)<0,3,T21);
T41:=IF (DDY>0 AND REF(DDY,1)>0 AND REF(DDY,2)>0 AND REF(DDY,3)>0 AND REF(DDY,4)<0,4,T31);
T51:=IF (DDY>0 AND REF(DDY,1)>0 AND REF(DDY,2)>0 AND REF(DDY,3)>0 AND REF(DDY,4)>0 AND REF(DDY,5)<0,5,T41);
T61:=IF (DDY>0 AND REF(DDY,1)>0 AND REF(DDY,2)>0 AND REF(DDY,3)>0 AND REF(DDY,4)>0 AND REF(DDY,5)>0 AND REF(DDY,6)<0,6,T51);
- 上一篇公式:通达信趋势顶底再优指标
- 下一篇公式:通达信版zig(4,n):最高最低转向公式zig4(指标 主图 通达信 贴图)加密