通达信不倒龙虎量能指标公式副图源码

[复制链接]
查看84 | 回复0 | 2021-8-26 21:26:30 | 显示全部楼层 |阅读模式

以下是通达信不倒龙虎量能指标公式副图源码(无源码的请下载附件导入)

A:=LARGEINTRDVOL*10000/FINANCE(7);

B:=LARGEOUTTRDVOL*10000/FINANCE(7);

A1:=SUM(A,3);

B1:=SUM(B,3);

A2:=DMA(A1,20);

B2:=DMA(B1,20);

DRAWBAND(A2/2,RGB(255,0,0),B2/2,RGB(0,210,250));

 

换手率:VOL/CAPITAL*100,COLORRED,NODRAW;

预换手:IF(CURRBARSCOUNT=1 AND PERIOD=5,换手率*240/FROMOPEN,DRAWNULL),COLORWHITE,NODRAW;

{量比:DYNAINFO(17),NODRAW,COLORWHITE;

日量比:V/REF(MA(V,5),1),NODRAW,COLORWHITE;}

STICKLINE(预换手,0,预换手/3,3,1)COLORWHITE;

STICKLINE(C>REF(C,1),0,换手率/3,3,1)COLORRED;

STICKLINE(C<REF(C,1),0,换手率/3,3,1)COLORGREEN;

STICKLINE(C=REF(C,1),0,换手率/3,3,1)COLORWHITE;

 

机构:(L2_VOL(0,0) - L2_VOL(0,1))*10000/FINANCE(7),NODRAW,COLORYELLOW;

大户:(L2_VOL(1,0) - L2_VOL(1,1))*10000/FINANCE(7),NODRAW,COLORRED;

中户:(L2_VOL(2,0) - L2_VOL(2,1))*10000/FINANCE(7),NODRAW,COLORMAGENTA;

散户:(L2_VOL(3,0) - L2_VOL(3,1))*10000/FINANCE(7),NODRAW,COLORGREEN;

主力:机构+大户,NODRAW,COLORYELLOW;

 

主力资金比:((A-B)/(A+B))*100,NODRAW,COLORRED;

主力占比:主力/换手率*100,NODRAW,COLORMAGENTA;

 

三日主力:SUM(主力,3),COLORYELLOW,LINETHICK2;

五日主力:SUM(主力,5),COLORRED;

十日主力:SUM(主力,10),COLORMAGENTA;

廿日主力:SUM(主力,20),COLORWHITE;

 

STICKLINE(机构<0,0,机构,2.5,0),COLORYELLOW,LINETHICK2;

STICKLINE(大户<0,0,大户,2,0),COLORRED,LINETHICK2;

STICKLINE(中户<0,0,中户,1.5,0),COLORMAGENTA;

STICKLINE(散户<0,0,散户,1,0),COLORGREEN;

STICKLINE(机构>0,0,机构,2.5,0),COLORYELLOW,LINETHICK2;

STICKLINE(大户>0,0,大户,2,0),COLORRED,LINETHICK2;

STICKLINE(中户>0,0,中户,1.5,0),COLORMAGENTA;

STICKLINE(散户>0,0,散户,1,0),COLORGREEN;

DRAWTEXT_FIX(C>0,0,0,0,'(【柱状图】:各类资金仓位(%)监测,机构为黄色、大户为红色、中户为浅红色、散户为绿色;0轴上方为买入,0轴下方为卖出。)'),COLORWHITE;

DRAWTEXT_FIX(C>0,0,0.08,0,'(【主力资金比、主力占比】:1.主力资金比:主力净买量与主力总成交量之比(%);2.主力占比:主力净买量与总成交量之比。)'),COLORWHITE;

DRAWTEXT_FIX(C>0,0,0.16,0,'(【红蓝色带】:主力买入成交量、主力卖出成交量3日总和的20日的动态移动平均。)'),COLORWHITE;

零轴:0,COLORWHITE;

DIFF:=(EMA(CLOSE,12)-EMA(CLOSE,26)),COLORGREEN,LINETHICK2;

{IF(DIFF>=REF(DIFF,1),DIFF,DRAWNULL),LINETHICK2,COLORRED;}

DEA:=EMA(DIFF,9),COLORWHITE;

MACD:=DIFF-DEA;

买:=REF(DIFF,1)<REF(DIFF,2) AND (DIFF>REF(DIFF,1));

卖:=DIFF>0 AND REF(DIFF,1)>REF(DIFF,2) AND {MACD<REF(MACD,1)}DIFF<REF(DIFF,1);

DRAWICON(买,A2*0.5,34);

DRAWICON(卖,B2*0.6,35);

1622455849.png

1622455849.png

回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则