通达信L1行情个股资金当日买卖量公式

2016-01-01 19:09:00来源:本站整理浏览:233

通达信L1行情个股资金当日买卖量公式

源码

现手买:=BUYVOL*DYNAINFO(7)*100/10000 COLOR0000FF,NODRAW;
现手卖:=SELLVOL*DYNAINFO(7)*100/10000 COLOR00FF00,NODRAW;
合:=ABS(现手买)+ABS(现手卖)COLOR80FFFF,NODRAW;
差:=ABS(现手买)-ABS(现手卖)COLOR80FFFF,NODRAW;
MPB1:=ABS(现手买)/合*100;
MPB2:=ABS(现手卖)/合*100;
TESTSKIP(NOT(现手买 OR 现手卖 OR 合 OR 差 OR MPB1 OR MPB2)!=0);
DRAWRECTREL(640,1000,940,940,RGB(190,190,190));
DRAWRECTREL(640,995,940,945,RGB(200,200,200));
DRAWRECTREL(640,990,940,950,RGB(210,210,210));
DRAWRECTREL(640,985,940,955,RGB(220,220,220));
DRAWRECTREL(640,980,940,960,RGB(230,230,230));
DRAWRECTREL(640,975,940,965,RGB(240,240,240));
DRAWRECTREL(640,970,940,970,RGB(250,250,250));
DRAWRECTREL(790-现手卖*210/合,1000,790,940,RGB(0,128,0));
DRAWRECTREL(790-现手卖*210/合,995,790,945,RGB(0,148,0));
DRAWRECTREL(790-现手卖*210/合,990,790,950,RGB(0,168,0));
DRAWRECTREL(790-现手卖*210/合,985,790,955,RGB(0,188,0));
DRAWRECTREL(790-现手卖*210/合,980,790,960,RGB(0,208,0));
DRAWRECTREL(790-现手卖*210/合,975,790,965,RGB(0,228,0));
DRAWRECTREL(790-现手卖*210/合,970,790,970,RGB(0,248,0));
DRAWRECTREL(790-现手卖*210/合,940,790-现手卖*210/合,1000,RGB(0,128,0));
DRAWRECTREL(790,1000,790+现手买*210/合,940,RGB(128,0,0));
DRAWRECTREL(790,995,790+现手买*210/合,945,RGB(148,0,0));
DRAWRECTREL(790,990,790+现手买*210/合,950,RGB(168,0,0));
DRAWRECTREL(790,985,790+现手买*210/合,955,RGB(188,0,0));
DRAWRECTREL(790,980,790+现手买*210/合,960,RGB(208,0,0));
DRAWRECTREL(790,975,790+现手买*210/合,965,RGB(228,0,0));
DRAWRECTREL(790,970,790+现手买*210/合,970,RGB(248,0,0));
DRAWRECTREL(790+现手买*210/合,940,790+现手买*210/合,1000,RGB(128,0,0));
DRAWRECTREL(789.8,940,790.2,1000,RGB(0,0.0,10));
DRAWRECTREL(639.8,940,640.2,1000,RGB(0,0,10));
DRAWRECTREL(939.8,940,940.2,1000,RGB(0,0,10));
DRAWRECTREL(0,940,1000,940.2,RGB(0,0,10));
DRAWTEXT_FIX(1,0.9,0.88,0,STRCAT(STRCAT("",CON2STR(现手买,1)),"万")),COLOR0000FF;
DRAWTEXT_FIX(1,0.61,0.88,0,STRCAT(STRCAT("",CON2STR(现手卖,1)),"万")),COLOR00FF00;
DRAWTEXT_FIX(CURRBARSCOUNT=1 AND(差)>0,0.755,0.88,0,STRCAT("  ",STRCAT(CON2STR(差,1),"万"))) COLOR0000FF;
DRAWTEXT_FIX(CURRBARSCOUNT=1 AND(差)<0,0.755,0.88,0,STRCAT("  ",STRCAT(CON2STR(差,1),"万"))) COLOR00FF00;
DRAWTEXT_FIX(CURRBARSCOUNT=1 AND(差)=0,0.755,0.88,0,STRCAT("  ",STRCAT(CON2STR(差,1),"万"))) COLOR80FFFF;
DRAWTEXT_FIX(1,0.58,0.97,0,STRCAT(STRCAT(" ",CON2STR(MPB2,1)),"%%")),COLOR00FF00;
DRAWTEXT_FIX(1,0.94,0.97,0,STRCAT(STRCAT("",CON2STR(MPB1,1)),"%%")),COLOR0000FF;
成交额:=V*C/100,NODRAW;{万元}
A2:=SUM((IF(((成交额/8>20) AND (CLOSE>(REF(CLOSE,1)))),成交额,0)),0);
A3:=SUM((IF(((成交额/8>20) AND (CLOSE<(REF(CLOSE,1)))),成交额,0)),0);
A6:=(A2+A3);
A7:=IF((ISLASTBAR),((100*A2)/A6),0);
A8:=IF((ISLASTBAR),((100*A3)/A6),0);
DD1:=1;
AAA1:=STRCAT(STRCAT("机构买",CON2STR((100*A2)/A6,0)),"%%");
AAA2:=STRCAT(STRCAT("机构卖",CON2STR((100*A3)/A6,0)),"%%");
AAA3:=STRCAT(STRCAT("总买入",CON2STR((100*(A2-A3))/A6,0)),"%%");
DRAWTEXT_FIX(DD1=1,0,0.02,0,AAA1),COLORRED;
DRAWTEXT_FIX(DD1=1,0,0.13,0,AAA2),COLOR00FF00;
DRAWTEXT_FIX(DD1=1,0,0.24,0,AAA3),COLOR00FFFF;

股票公式栏目导航

精品指标推荐

最新热门

本类随机推荐

相关公式