通达信公式源码概况:

指标类别:通达信公式

授权方式: 免费版

指标评级: ★★★★★

指标分类: 策略

画线方法: 副图

一、通达信开盘抓涨停指标公式

  

AA:=IF(COUNT(C/REF(C,1)>1.0985,60)=12,5.12,  

IF(COUNT(C/REF(C,1)>1.0985,60)=11,5.11,  

IF(COUNT(C/REF(C,1)>1.0985,60)=10,4.10,  

IF(COUNT(C/REF(C,1)>1.0985,60)=9,4.09,  

IF(COUNT(C/REF(C,1)>1.0985,60)=8,4.08,  

IF(COUNT(C/REF(C,1)>1.0985,60)=7,4.07,  

IF(COUNT(C/REF(C,1)>1.0985,60)=6,3.06,  

IF(COUNT(C/REF(C,1)>1.0985,60)=5,3.05,  

IF(COUNT(C/REF(C,1)>1.0985,60)=4,3.04,  

IF(COUNT(C/REF(C,1)>1.0985,60)=3,2.03,  

IF(COUNT(C/REF(C,1)>1.0985,60)=2,2.02,  

IF(COUNT(C/REF(C,1)>1.0985,60)=1,1.01,0))))))))))));  

IF(COUNT(C/REF(C,1)>1.0985,60)=21,6.21,  

IF(COUNT(C/REF(C,1)>1.0985,60)=20,6.20,  

IF(COUNT(C/REF(C,1)>1.0985,60)=19,6.19,  

IF(COUNT(C/REF(C,1)>1.0985,60)=18,6.18,  

IF(COUNT(C/REF(C,1)>1.0985,60)=17,6.17,  

IF(COUNT(C/REF(C,1)>1.0985,60)=16,6.16,  

IF(COUNT(C/REF(C,1)>1.0985,60)=15,5.15,  

IF(COUNT(C/REF(C,1)>1.0985,60)=14,5.14,  

IF(COUNT(C/REF(C,1)>1.0985,60)=13,5.13,  

AA)))))))));  

{120日内涨停为第几档多少次}  

{  

AA:=IF(COUNT(C/REF(C,1)>1.0985,120)=12,5.12,  

IF(COUNT(C/REF(C,1)>1.0985,120)=11,5.11,  

IF(COUNT(C/REF(C,1)>1.0985,120)=10,4.10,  

IF(COUNT(C/REF(C,1)>1.0985,120)=9,4.09,  

IF(COUNT(C/REF(C,1)>1.0985,120)=8,4.08,  

IF(COUNT(C/REF(C,1)>1.0985,120)=7,4.07,  

IF(COUNT(C/REF(C,1)>1.0985,120)=6,3.06,  

IF(COUNT(C/REF(C,1)>1.0985,120)=5,3.05,  

IF(COUNT(C/REF(C,1)>1.0985,120)=4,3.04,  

IF(COUNT(C/REF(C,1)>1.0985,120)=3,2.03,  

IF(COUNT(C/REF(C,1)>1.0985,120)=2,2.02,  

IF(COUNT(C/REF(C,1)>1.0985,120)=1,1.01,0))))))))))));  

IF(COUNT(C/REF(C,1)>1.0985,120)=21,6.21,  

IF(COUNT(C/REF(C,1)>1.0985,120)=20,6.20,  

IF(COUNT(C/REF(C,1)>1.0985,120)=19,6.19,  

IF(COUNT(C/REF(C,1)>1.0985,120)=18,6.18,  

IF(COUNT(C/REF(C,1)>1.0985,120)=17,6.17,  

IF(COUNT(C/REF(C,1)>1.0985,120)=16,6.16,  

IF(COUNT(C/REF(C,1)>1.0985,120)=15,5.15,  

IF(COUNT(C/REF(C,1)>1.0985,120)=14,5.14,  

IF(COUNT(C/REF(C,1)>1.0985,120)=13,5.13,  

AA)))))))));  

}  

STICKLINE(HOUR>=9ANDHOUR<10,0,V/((TIME-93000)/100)*240,4.5,1),COLORWHITE;  

STICKLINE(HOUR>=10ANDHOUR<11,0,V/((TIME-100000)/100+30)*240,4.5,1),COLORWHITE;  

STICKLINE(HOUR>=11ANDHOUR<12,0,V/((TIME-110000)/100+90)*240,4.5,1),COLORWHITE;  

STICKLINE(HOUR>=13ANDHOUR<=14,0,V/((TIME-130000)/100+120)*240,4.5,1),COLORWHITE;  

STICKLINE(HOUR>=14ANDHOUR<=15,0,V/((TIME-140000)/100+180)*240,4.5,1),COLORWHITE;  

VAR1:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN));  

主动买盘:=IF(CLOSE>OPEN,VAR1*(HIGH-LOW),IF(CLOSE<OPEN,VAR1*((HIGH-OPEN)+(CLOSE-LOW)),VOL/2));  

主动卖盘:=IF(CLOSE>OPEN,0-VAR1*((HIGH-CLOSE)+(OPEN-LOW)),IF(CLOSE<OPEN,0-VAR1*(HIGH-LOW),0-VOL/2));  

STICKLINE(C>O,0,VOL,4.5,1),COLORRED;  

STICKLINE(C<O,0,VOL,4.5,1),COLORFFFF00;  

STICKLINE(C=OANDC<REF(C,1),0,VOL,4.5,1),COLORFFFF00;  

STICKLINE(C=OANDC>REF(C,1),0,VOL,4.5,1),COLORRED;  

STICKLINE(主动买盘>0,0,主动买盘,4.5,0),COLORRED;  

换手:VOL/CAPITAL*100;  

STICKLINE(换手>=3AND换手<8,0,主动买盘,2,0),COLORYELLOW;  

STICKLINE(换手>=8,0,主动买盘,2,0),COLORGREEN;  

MA5:MA(VOL,5),COLORYELLOW;  

MA13:MA(VOL,13),COLORWHITE;  

DRAWTEXT(CROSS(MA5,MA13),CROSS(MA5,MA13),'*'),COLORYELLOW;  

量2:=V=LLV(V,20);量底:STICKLINE(H,REF(H,BARSLAST(量2)),REF(H,BARSLAST(量2)),5,0),COLORWHITE;  

VOL,VOLSTICK,PRECIS0;  

mm:=0;  

IFPFFIN(4251,0)>0Thenbegin  

mm:=PFFIN(4251,0);end;  

流通盘:=CAPITAL-mm/100;  

dbhs:if(capital<2000000,v/capital*100,v/流通盘*100),linethick0;  

标准量:if(count(v>流通盘/1000,0)>0,流通盘/1000,0),colorff00ff,PRECIS0;  

STICKLINE(C<REF(C,1),0,VOL,5,0),COLORgreen;  

STICKLINE(C>REF(C,1),0,VOL,5,0),COLOR4040FF;  

STICKLINE(C=REF(C,1),0,VOL,5,0),COLORwhite;  

总量:SUM(V,0),linethick0,PRECIS0,colorcyan;  

最大量:HHV(v,0),POINTDOT,COLORwhite,PRECIS0;  

最大换手:HHV(dbhs,240),DOTLINE,COLORwhite,PRECIS2,linethick0;  

STICKLINE(C<REF(C,1)andv>ref(最大量,1)andtime>94200,0,VOL,5,0),COLOR3d,colorgreen,LINETHICK2;  

STICKLINE(C>REF(C,1)andv>ref(最大量,1)andtime>94200,0,VOL,5,0),COLORred,COLOR3d,LINETHICK2;  

STICKLINE(C=REF(C,1)andv>ref(最大量,1)andtime>94200,0,VOL,5,0),COLORwhite,LINETHICK2;  

STICKLINE(v>ref(最大量,1)*1.5andc>ref(c,1)anddbhs>0.15andtime>94500,0,VOL,5,0),COLORyellow,COLOR3d,LINETHICK2;  

STICKLINE(C>REF(C,1)anddbhs>0.22andtime<94200,0,VOL,5,0),COLOR66ffff,color3d,LINETHICK2;  

lxtp:=((v>ref(v,1)anddbhs>=0.1andref(v,1)>ref(最大量,2))or(v>ref(最大量,1)anddbhs>=0.08andref(v,2)>ref(最大量,3)))andc>ref(c,1);  

lxtp1:=((v>ref(v,1)*0.9anddbhs>=0.1andref(v,1)>ref(最大量,2))or(v>ref(最大量,1)*0.9anddbhs>=0.1andref(v,2)>ref(最大量,3)))andc>ref(c,1);  

DRAWTEXT(lxtp1,v*0.98,'★'),ALIGN1,VALIGN1,COLORdd22b8,LINETHICK3;  

DRAWTEXT(lxtp,v*0.98,'★'),ALIGN1,VALIGN1,COLORRED,LINETHICK3;  

n3:=barslast(cross(lxtp,0));  

踪3:if(lxtp>0,n3+1,0),linethick0;  

时长:=TIME>=093000andTIME<=143000;  

量数:sum(踪3,时长),linethick0,PRECIS0;  

xxx:count(量数,5);  

比例:=v/ma(v,10)*100;  

DRAWTEXTREL(2,130,'均量比:'),COLORYELLOW;  

DRAWTEXTREL(60,130,NUMTOSTRN(比例,2)+'%'),COLORYELLOW;  

DRAWRECTREL(125,150,375,225,RGB(30,30,30)),COLORYELLOW;  

DRAWRECTREL(125,150,125+比例*2.52,225,RGB(155,50,50)),COLORYELLOW;  

bl:=sum(v,0)/"引用.v1#day"*100;  

DRAWTEXTREL(2,300,'昨日比:'),COLORYELLOW;  

DRAWTEXTREL(60,300,NUMTOSTRN(bl,2)+'%'),COLORYELLOW;  

DRAWRECTREL(125,300,375,375,RGB(30,30,30)),COLORYELLOW;  

DRAWRECTREL(125,300,125+bl*2.52,375,RGB(155,50,50)),COLORYELLOW;  

OBVJ:=SUM(IF(CLOSE>REF(CLOSE,1),VOL,IF(CLOSE<REF(CLOSE,1),-VOL,0)),0);  

VAs:=OBVJ/2;  

H1:=hhvall(hhv(C,0));  

L1:=llvall(llv(C,0));  

P1:=H1-L1;  

F:=L1-P1*0.5;  

STICKLINE(OBVJ>=0,F,F+VAs,4,0),Color0599ff,LAYER6;  

STICKLINE(OBVJ<0,F,F-VAs,4,0),Color003900,LAYER6;  

FILLRGN(F,L1,F<L1,RGB(30,30,30)),LINETHICK2,LAYER7;

image.png

[源码注释]通达信公式动态翻译结果

输出XG: 收盘价/10日前的收盘价<1.2 并且 收盘价/10日前的收盘价>1.1

每日通达信公式解答:

  

编写条件:  

昨日成交量大于近5个交易日平均成交量的1倍,昨日换手率大于1,昨日跌幅大于3%的选股公式。  

编写方法:  

XG:REF(V,1)>SUM(V,5)/5*2ANDREF(HSL.HSL>1ANDC/REF(C,1)<=0.97,1);

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