大智慧盘口分析指标公式股票软件源码如下: 说明: 副图指标,适用周期:分笔。 总买、总卖、大单、小单、资金进出等一清二楚! input:n1(2,1,50),n2(18,1,100); DRAWTEXTREL(29,29,STKLABEL),LINETHICK6,Colorcc99ff; DRAWTEXTREL(144,29,STKNAME),LINETHICK6,Colorff0000; DRAWTEXTREL(30,30,STKLABEL),LINETHICK6,Colorffff00; DRAWTEXTREL(145,30,STKNAME),LINETHICK6,Color00ffff; DRAWTEXTREL(746,189,'盘 口 分 析'),LINETHICK6,Color00ffff; DRAWTEXTREL(748,191,'盘 口 分 析'),LINETHICK6,Color0000ff; DRAWTEXTREL(295,45,'流通:'+NUMTOSTRN(FINANCE2(37),0)+' 收益:'+NUMTOSTRN(FINANCE2(3),2)+' 市盈:'+NUMTOSTRN(DYNAINFO(39),2)+' 市净:'+NUMTOSTRN(DYNAINFO(58),2)+' 换手:'+NUMTOSTRN(DYNAINFO(37),2)),LINETHICK3,Color9999ff; DRAWTEXTREL(20,120,'---------------------------------------------------------'),LINETHICK3,Colorffffff; mr:=BUYVOL*c/100; zmr:=sum(mr,0); mc:=SELLVOL*c/100; zmc:=sum(mc,0); rch:=zmr+zmc; rcc:=zmr-zmc; mr0:=if(mr<5 ,mr,0); zmr0:=sum(mr0,0); mc0:=if(mc<5 ,mc,0); zmc0:=sum(mc0,0); mr5:=if(mr<10 and mr>=5 ,mr,0); zmr5:=sum(mr5,0); mc5:=if(mc<10 and mc>=5,mc,0); zmc5:=sum(mc5,0); mr10:=if(mr<25 and mr>=10 ,mr,0); zmr10:=sum(mr10,0); mc10:=if(mc<25 and mc>=10 ,mc,0); zmc10:=sum(mc10,0); mr25:=if(mr<50 and mr>=25 ,mr,0); zmr25:=sum(mr25,0); mc25:=if(mc<50 and mc>=25 ,mc,0); zmc25:=sum(mc25,0); mr50:=if(mr<75 and mr>=50 ,mr,0); zmr50:=sum(mr50,0); mc50:=if(mc<75 and mc>=50 ,mc,0); zmc50:=sum(mc50,0); mr75:=if(mr<100 and mr>=75,mr,0); zmr75:=sum(mr75,0); mc75:=if(mc<100 and mc>=75,mc,0); zmc75:=sum(mc75,0); mr100:=if(mr>=100 ,mr,0); zmr100:=sum(mr100,0); mc100:=if(mc>=100 ,mc,0); zmc100:=sum(mc100,0); jg:=10*n2;mr200:=if(mr>jg ,mr,0); zmr200:=sum(mr200,0); mc200:=if(mc>jg,mc,0); zmc200:=sum(mc200,0); mmc200:=zmr200-zmc200; mmc0:=zmr0-zmc0; mmc5:=zmr5-zmc5; mmc10:=zmr10+zmr25+zmr50-zmc10-zmc25-zmc50; mmc75:=zmr75+zmr100-zmc75-zmc100; DRAWTEXTREL(20,492,'---------------------------------------------------------'),LINETHICK3,Colorffffff; IF BARSTATUS=2 and (zmr) THEN BEGIN DRAWTEXTREL(34,545,' 总买入: '+NUMTOSTRN(zmr,2)),LINETHICK2,COLORff00ff;end; IF BARSTATUS=2 and (zmc) THEN BEGIN DRAWTEXTREL(261,545,' 总卖出: '+NUMTOSTRN(zmc,2)),LINETHICK2,COLORffff00;end; IF BARSTATUS=2 and (zmr0) THEN BEGIN DRAWTEXTREL(17,608,' 5万下小单买入: ' +NUMTOSTRN(zmr0,2)),LINETHICK1,COLOR0000ff;end; IF BARSTATUS=2 and (zmc0) THEN BEGIN DRAWTEXTREL(264,608,' 5万下小单卖出: '+NUMTOSTRN(zmc0,2)),LINETHICK1,COLOR00ff00;end; IF BARSTATUS=2 and (zmr5) THEN BEGIN DRAWTEXTREL(17,660,' 5 万中单买入: '+NUMTOSTRN(zmr5,2)),LINETHICK1,COLOR9900ff;end; IF BARSTATUS=2 and (zmc5) THEN BEGIN DRAWTEXTREL(264,660,' 5 万中单卖出: '+NUMTOSTRN(zmc5,2)),LINETHICK1,COLOR99ff00;end; IF BARSTATUS=2 and (zmr10) THEN BEGIN DRAWTEXTREL(17,712,' 10 万大单买入: '+NUMTOSTRN(zmr10,2)),LINETHICK1,COLOR0000ff;end; IF BARSTATUS=2 and (zmc10) THEN BEGIN DRAWTEXTREL(264,712,' 10 万大单卖出: '+NUMTOSTRN(zmc10,2)),LINETHICK1,COLOR00ff00;end; IF BARSTATUS=2 and (zmr25) THEN BEGIN DRAWTEXTREL(17,764,' 25 万大单买入: '+NUMTOSTRN(zmr25,2)),LINETHICK1,COLOR9900ff;end; IF BARSTATUS=2 and (zmc25) THEN BEGIN DRAWTEXTREL(264,764,' 25 万大单卖出: '+NUMTOSTRN(zmc25,2)),LINETHICK1,COLOR99ff00;end; IF BARSTATUS=2 and (zmr50) THEN BEGIN DRAWTEXTREL(17,816,' 50 万大单买入: '+NUMTOSTRN(zmr50,2)),LINETHICK1,COLOR0000ff;end; IF BARSTATUS=2 and (zmc50) THEN BEGIN DRAWTEXTREL(264,816,' 50 万大单卖出: '+NUMTOSTRN(zmc50,2)),LINETHICK1,COLOR00ff00;end; IF BARSTATUS=2 and (zmr75) THEN BEGIN DRAWTEXTREL(17,868,' 75 万大单买入: '+NUMTOSTRN(zmr75,2)),LINETHICK1,COLOR9900ff;end; IF BARSTATUS=2 and (zmc75) THEN BEGIN DRAWTEXTREL(264,868,' 75 万大单卖出: '+NUMTOSTRN(zmc75,2)),LINETHICK1,COLOR99ff00;end; IF BARSTATUS=2 and (zmr100) THEN BEGIN DRAWTEXTREL(17,920,'100 万大单买入: '+NUMTOSTRN(zmr100,2)),LINETHICK1,COLOR0000ff;end; IF BARSTATUS=2 and (zmc100) THEN BEGIN DRAWTEXTREL(264,920,' 100 万大单卖出: '+NUMTOSTRN(zmc100,2)),LINETHICK1,COLOR00ff00;end; IF BARSTATUS=2 and (zmr+zmc) THEN BEGIN DRAWTEXTREL(475,545,' 成交总额: '+NUMTOSTRN(zmr+zmc,2)),LINETHICK2,COLOR6699ff;end; IF BARSTATUS=2 and (rcc) and rcc<0 THEN BEGIN DRAWTEXTREL(480,608,' 总成交净额: '+NUMTOSTRN(rcc,2)),LINETHICK1,COLORffff00;end; IF BARSTATUS=2 and (rcc) and rcc>0 THEN BEGIN DRAWTEXTREL(480,608,' 总成交净额: '+NUMTOSTRN(rcc,2)),LINETHICK1,COLOR9966ff;end; IF BARSTATUS=2 and (mmc0) and mmc0<0 THEN BEGIN DRAWTEXTREL(480,660,' 小单净额: '+NUMTOSTRN(mmc0,2)),LINETHICK1,COLORff9900;end; IF BARSTATUS=2 and (mmc0) and mmc0>0 THEN BEGIN DRAWTEXTREL(480,660,' 小单净额: '+NUMTOSTRN(mmc0,2)),LINETHICK1,COLOR9966ff;end; IF BARSTATUS=2 and (mmc5) and mmc5<0 THEN BEGIN DRAWTEXTREL(480,712,' 中单净额: '+NUMTOSTRN(mmc5,2)),LINETHICK1,COLORff6600;end; IF BARSTATUS=2 and (mmc5) and mmc5>0 THEN BEGIN DRAWTEXTREL(480,712,' 中单净额: '+NUMTOSTRN(mmc5,2)),LINETHICK1,COLOR9966ff;end; IF BARSTATUS=2 and (mmc10) and mmc10<0 THEN BEGIN DRAWTEXTREL(480,764,' 大单净额: '+NUMTOSTRN(mmc10,2)),LINETHICK1,COLORff9900;end; IF BARSTATUS=2 and (mmc10) and mmc10>0 THEN BEGIN DRAWTEXTREL(480,764,' 大单净额: '+NUMTOSTRN(mmc10,2)),LINETHICK1,COLOR0000ff;end; IF BARSTATUS=2 and (mmc75) and mmc75<0 THEN BEGIN DRAWTEXTREL(480,816,' 特大净额: '+NUMTOSTRN(mmc75,2)),LINETHICK1,COLORff6600;end; IF BARSTATUS=2 and (mmc75) and mmc75>0 THEN BEGIN DRAWTEXTREL(480,816,' 特大净额: '+NUMTOSTRN(mmc75,2)),LINETHICK1,COLOR0000ff;end; xzj:=mmc0+mmc5;dzj:=mmc10+mmc75; IF BARSTATUS=2 and (xzj) and xzj<0 THEN BEGIN DRAWTEXTREL(725,640,'小资金流出: '+NUMTOSTRN(ABS(xzj),2)),LINETHICK3,COLORff9900;end; IF BARSTATUS=2 and (xzj) and xzj>0 THEN BEGIN DRAWTEXTREL(725,640,'小资金流入: '+NUMTOSTRN(xzj,2)),LINETHICK3,COLOR9966ff;end; IF BARSTATUS=2 and (dzj) and dzj<0 THEN BEGIN DRAWTEXTREL(725,734,'大资金流出: '+NUMTOSTRN(ABS(dzj),2)),LINETHICK3,COLORff9900;end; IF BARSTATUS=2 and (dzj) and dzj>0 THEN BEGIN DRAWTEXTREL(720,734,'大资金流入: '+NUMTOSTRN(dzj,2)),LINETHICK3,COLOR0000ff;end; IF BARSTATUS=2 and (mmc200) and mmc200<0 THEN BEGIN DRAWTEXTREL(479,898,' 大机构减仓: '+NUMTOSTRN(abs(mmc200),2)),LINETHICK4,COLOReeeeee;end; IF BARSTATUS=2 and (mmc200) and mmc200<0 THEN BEGIN DRAWTEXTREL(480,899,' 大机构减仓: '+NUMTOSTRN(abs(mmc200),2)),LINETHICK4,COLORff0000;end; IF BARSTATUS=2 and (mmc200) and mmc200>0 THEN BEGIN DRAWTEXTREL(479,898,' 大机构增仓: '+NUMTOSTRN(mmc200,2)),LINETHICK4,COLOReeeeee;end; IF BARSTATUS=2 and (mmc200) and mmc200>0 THEN BEGIN DRAWTEXTREL(480,899,' 大机构增仓: '+NUMTOSTRN(mmc200,2)),LINETHICK4,COLOR0000ff;end; mrl:=SUM(BUYVOL,0); mcl:=SUM(SELLVOL,0); dydd:=100*n1; tddr:=SUM(if(BUYVOL>800,BUYVOL,0),0); tddc:=SUM(if(SELLVOL>800,SELLVOL,0),0); ddr:=SUM(if(BUYVOL>dydd,BUYVOL,0),0); ddc:=SUM(if(SELLVOL>dydd,SELLVOL,0),0); xdr:=mrl-ddr; xdc:=mcl-ddc; dr:=sum(if(BUYVOL>dydd,BUYVOL,0)*c,0); drj:=dr/ddr; dc:=sum(if(SELLVOL>dydd,SELLVOL,0)*c,0); dcj:=dc/ddc; zb:=sum(if(BUYVOL>0,1,0),0)+sum(if(SELLVOL>0,1,0),0); DRAWTEXTABS(20,55,' 总买入量: '+mrl),Color0099ff,LINETHICK2; DRAWTEXTABS(215,55,' 总卖入量: '+mcl),Colorffff66,LINETHICK2; DRAWTEXTABS(20,74,'■ 特大买入: '+tddr),Color0000FF,LINETHICK2; DRAWTEXTABS(170,74,''+FLOOR(tddr/(mrl+mcl)*100)+' %'),Color0000ff,LINETHICK2; {股票软件下载网-股票公式网站 www.gpxiazai.com} DRAWTEXTABS(215,74,'■ 特大卖出: '+tddc),Color00ff00,LINETHICK2; DRAWTEXTABS(365,74,''+FLOOR(tddc/(mrl+mcl)*100)+' %'),Color00ff00,LINETHICK2; DRAWTEXTABS(20,93,'■ 大单买入: '+ddr),Colorcc66ff,LINETHICK2; DRAWTEXTABS(170,93,''+FLOOR(ddr/(mrl+mcl)*100)+' %'),Colorcc66ff,LINETHICK2; DRAWTEXTABS(215,93,'■ 大单卖出: '+ddc),Colorff9966,LINETHICK2; DRAWTEXTABS(365,93,''+FLOOR(ddc/(mrl+mcl)*100)+' %'),Colorff9966,LINETHICK2; DRAWTEXTABS(20,112,'■ 小单买入: '+xdr),Color99ccFF,LINETHICK2; DRAWTEXTABS(170,112,''+FLOOR(xdr/(mrl+mcl)*100)+' %'),Color99ccFF,LINETHICK2; DRAWTEXTABS(215,112,'■ 小单卖出: '+xdc),Colorccffcc,LINETHICK2; DRAWTEXTABS(365,112,''+FLOOR(xdc/(mrl+mcl)*100)+' %'),Colorccffcc,LINETHICK2; DRAWTEXTABS(20,131,' 大单买均价: '+drj),Color6600FF,LINETHICK2; DRAWTEXTABS(215,131,' 大单卖均价: '+dcj),Color99ff33,LINETHICK2; DRAWTEXTABS(415,55,' 总成交量: '+(mrl+mcl)),Colorccccff,LINETHICK2; DRAWTEXTABS(415,74,' 特大净量: '+(tddr-tddc)),Colorcc66ff,LINETHICK2; DRAWTEXTABS(415,93,' 大单净量: '+(ddr-ddc)),Colorccff33,LINETHICK2; DRAWTEXTABS(415,112,' 小单净量: '+(xdr-xdc)),Colorffcc66,LINETHICK2; DRAWTEXTABS(415,131,' 总买净量: '+(mrl-mcl)+' 总笔数: '+zb+' 每笔 '+NUMTOSTRN(((mrl+mcl)/zb),0)+' 手'),Color00ffff,LINETHICK2; DRAWTEXTABS(562,96,'参数1:'+dydd+' 参数2:'+jg),LINETHICK3,Colorffffff; STICKLINE((DYNAINFO(8) AND DISPSTATUS=2),0,DYNAINFO(8),60,1),COLORFFFFFF; STICKLINE((tddr+tddc+ddr+ddc+xdr+xdc AND DISPSTATUS=2),0,DYNAINFO(8),60,0),Color99ccFF; STICKLINE((tddr+tddc+ddr+ddc+xdc AND DISPSTATUS=2),0,tddr+tddc+ddr+ddc+xdc,60,0),Colorcc66ff; STICKLINE((tddr+tddc+ddc+xdc AND DISPSTATUS=2),0,tddr+tddc+ddc+xdc,60,0),Color0000FF; STICKLINE((tddc+ddc+xdc AND DISPSTATUS=2),0,tddc+ddc+xdc,60,0),Color00ff00; STICKLINE((ddc+xdc AND DISPSTATUS=2),0,ddc+xdc,60,0),Colorff9966; STICKLINE((xdc AND DISPSTATUS=2),0,xdc,60,0),Colorccffcc; |