通达信公式源码概况:
指标类别:通达信公式
授权方式: 免费版
指标评级: ★★★★★
指标分类: 策略
画线方法: 副图
一、通达信凹口倍量柱选股指标公式
百分比:=5;
ZIG(3,百分比);{此行可省};
波峰距离:PEAKBARS(3,百分比,1),NODRAW;
波谷值:=TROUGH(2,百分比,1);
波谷距离:=TROUGHBARS(2,百分比,1);
距离:=CURRBARSCOUNT,NODRAW;
C2:=REF(C,1);
比前跌率:=(C2-C)*100/C2;
本日跌率:=(O-C)*100/O;
距离FK1:=波峰距离-1;{波峰右边K距离}
线位置:=REF(L,距离FK1),{NODRAW};
TJ1:=波峰距离>波谷距离+5AND波峰距离<120;
TJ2:=REF(本日跌率,距离FK1)>3ORREF(比前跌率,距离FK1)>3;{跌率>3%}
TJ3:=距离<240;
TJ4:=REF(C,距离FK1)<REF(O,距离FK1){阴K}
ANDREF(C,距离FK1)<REF(MIN(C,O),距离FK1+1);{跌破前K}
画线条件:=线位置=REF(线位置,1)ANDTJ2ANDTJ4;{画线条件}
STICKLINE(画线条件,线位置,线位置,15,1),COLORMAGENTA;{画线}
画线:IF(画线条件,线位置,DRAWNULL),COLORMAGENTA;{画线}
打字条件:=FILTER(画线条件ANDTJ1ANDTJ3,20);
DRAWTEXT(打字条件,线位置*1.01,'凹口平衡线'),COLORMAGENTA;{此行可省};
{=============大阴线实顶平衡线,加上去主图花了一些========================}
MA5:=MA(C,5);
平衡线:=(比前跌率>4OR本日跌率>4)ANDC<MA5;{4可自己调为3-10}
STICKLINE(平衡线,O,O,45,-1),COLORGREEN;{画绿虚线};
〖量〗:vol,VOLstICK;
STICKLINE(V>=3*REF(V,1),V/3,V/3,3.9,0),COLORWHITE;
STICKLINE(V>=2*REF(V,1),V/2,V/2,3.9,0),COLORYELLOW;
流通〖亿〗:CAPITAL/1000000,LINETHICK0;
内外比:DYNAINFO(51),COLORYELLOW;
倍量:(vol/REF(VOL,1)>2andCOUNT(CLOSE>OPEN,1))or(LOW>REF(HIGH,1)andCOUNT(OPEN>CLOSE,1)andVOL/REF(VOL,1)>2),stICK,COLORBLUE,linethick4
AA:=VOL;
BB:=REF(MA(VOL,5),1);
CC:=AA/BB;
A1:=CC>=0.001ANDCC<0.5;
A2:=CC>=0.5ANDCC<0.8;
A3:=CC>=0.8ANDCC<1.5;
A4:=CC>=1.5ANDCC<2.5;
A5:=CC>=2.5ANDCC<5.0;
A6:=CC>=5.0ANDCC<10.0;
A7:=CC>=10.0ANDCC<20.0;
关注线:1.5,COLORFFFFFF,LINETHICK1;
放量线:2.5,COLORFF00FF,LINETHICK1;
STICKLINE(A1,0,CC,2.5,0),COLOREAEAEA;
STICKLINE(A1,0,CC,1.5,0),COLOREBEBEB;
STICKLINE(A1,0,CC,0.8,0),COLOREDEDED;
STICKLINE(A1,0,CC,0.1,0),COLORE8E8E8;
严重缩量:A7,STICK,COLORFFFFFF;
STICKLINE(A2,0,CC,2.5,0),COLOR009900;
STICKLINE(A2,0,CC,1.5,0),COLOR00BB00;
STICKLINE(A2,0,CC,0.8,0),COLOR00DD00;
STICKLINE(A2,0,CC,0.1,0),COLOR00FF00;
缩量:A7,STICK,COLOR00FF00;
STICKLINE(A3,0,CC,2.5,0),COLOR009900;
STICKLINE(A3,0,CC,1.5,0),COLORBBBB00;
STICKLINE(A3,0,CC,0.8,0),COLORDDDD00;
STICKLINE(A3,0,CC,0.1,0),COLORFFFF00;
正常量比:A7,STICK,COLORFFFF00;
STICKLINE(A4,0,CC,2.5,0),COLOR00AAFF;
STICKLINE(A4,0,CC,1.5,0),COLOR00BBFF;
STICKLINE(A4,0,CC,0.8,0),COLOR00CCFF;
STICKLINE(A4,0,CC,0.1,0),COLOR00DDFF;
温和放量:A4,STICK,COLOR00CCFF;
STICKLINE(A5,0,CC,2.5,0),COLORFF00FF;
STICKLINE(A5,0,CC,1.5,0),COLORFF33FF;
STICKLINE(A5,0,CC,0.8,0),COLORFF66FF;
STICKLINE(A5,0,CC,0.1,0),COLORFF99FF;
明显放量:A5,STICK,COLORMAGENTA;
STICKLINE(A6,0,CC,2.8,0),COLOR000088;
STICKLINE(A6,0,CC,1.5,0),COLOR0000AA;
STICKLINE(A6,0,CC,0.8,0),COLOR0000CC;
STICKLINE(A6,0,CC,0.1,0),COLOR0000EE;
剧烈放量:A6,STICK,COLOR0000FF;
STICKLINE(A7,0,CC,2.8,0),COLOR995500;
STICKLINE(A7,0,CC,1.5,0),COLORBB6600;
STICKLINE(A7,0,CC,0.8,0),COLORDD7700;
STICKLINE(A7,0,CC,0.1,0),COLORFF8800;
反向操作:A7,STICK,COLORFF8800;
今日量比:VOL/REF(MA(VOL,5),1),COLORFFFFFF,NODRAW;
DRAWTEXT(倍量,0.75,'倍量'),COLORBLUE;
百日地量:LLV(VOL,100)>=VOL,STICK,COLORRED,LINETHICK4;
DRAWTEXT(百日地量,0.5,'地量'),colorred;
倍缩量:VOL/REF(VOL,1)<0.5,STICK,COLORFF00FF,linethick2;
缩量涨:
COUNT(C>REF(C,1),2)>=2ANDCOUNT(VOL<REF(VOL,1),2)>=2,COLORYELLOW,STICK,linethick2;
黑太阳:
IF(LOW>REF(HIGH,1)andCOUNT(OPEN>CLOSE,1),0.5,0),STICK,colorwhite,linethick4;
DRAWTEXT(黑太阳,0.2,'黑太阳'),COLORwhite;
红太阳:
IF(LOW>REF(HIGH,1)andCOUNT(OPEN<CLOSE,1),0.5,0),STICK,colorred,linethick4;
DRAWTEXT(红太阳,0.2,'红太阳'),COLORRED;
A7:=C-REF(C,1);
A8:=100*Ema(EMA(A7,6),6)/EMA(EMA(Abs(A7),6),6);
买进:(LLV(A8,2)=LLV(A8,7)ANDCOUNT(A8<0,2)ANDcrOSS(A8,MA(A8,2))),linethick1,COLORyellow;
DRAWTEXT(买进,0.5,'↖买进'),COLORYELLOW;
明日抄底:(TROUGHBARS(3,15,1)=0)AND(HIGH>LOW+0.01),linethick2,COLORred;
单日量比:V/REF(V,1),COLORWHITE;
五日量比:V/(REF(ma(V,5),1)/240),COLORYELLOW;
5换:SUM(100*V/CAPITAL,5),LINETHICK0;
10换:SUM(100*V/CAPITAL,10),LINETHICK0;
20换:SUM(100*V/CAPITAL,20),LINETHICK0;
MID:=(3*CLOSE+LOW+OPEN+HIGH)/6;取舍线:(20*MID+19*REF(MID,1)+18*REF(MID,2)+17*REF(MID,3)+16*REF(MID,4)+15*REF(MID,5)+14*REF(MID,6)+13*REF(MID,7)+12*REF(MID,8)+11*REF(MID,9)+10*REF(MID,10)+9*REF(MID,11)+8*REF(MID,12)+7*REF(MID,13)+6*REF(MID,14)+5*REF(MID,15)+4*REF(MID,16)+3*REF(MID,17)+2*REF(MID,18)+REF(MID,20))/210,LINETHICK1,COLORYELLOW;生命线:MA(取舍线,6),LINETHICK1,COLORRED;ZT:=C/REF(C,1)>1.098;BH:=BARSLAST(ZT);STICKLINE(ZT,REF(O,BH),REF(C,BH),2,0),COLORYELLOW;MMM:=REFDATE(HHV(H,120),DATE);NNN:=REFDATE(LLV(L,120),DATE);CR:(H+L+C)/3,NODRAW,COLORRED;AAA:=REFDATE(HHV(CR,45),DATE);BBB:=REFDATE(LLV(CR,45),DATE);CCC:=REFDATE(HHV(CR,15),DATE);DDD:=REFDATE(LLV(CR,233),DATE);STICKLINE(REF(AAA,1),AAA,AAA,5,0),COLOR773300;STICKLINE(REF(BBB,1),BBB,BBB,5,0),COLOR005599;STICKLINE(REF(CCC,1),CCC,CCC,5,0),COLOR117711;STICKLINE(REF(DDD,1),DDD,DDD,5,0),COLOR777777;
[源码注释]通达信公式动态翻译结果
ZT赋值:如果模糊匹配品种名称ORNAMELIKE('*ST'),返回收盘价=计算涨停价,否则返回如果模糊匹配品种代码OR(模糊匹配品种代码ANDDATE>=1200824),返回收盘价=计算涨停价,否则返回收盘价=计算涨停价
8日前的ZT AND 成交量(手)<8日前的成交量(手)/2 AND 收盘价<收盘价的10日简单移动平均 AND 8日内最低价的最高值<8日前的(最高价+最低价)/2 AND 8日内最低价的最低值>8日前的最低价
每日通达信公式解答:
编写要求:
选股公式。 1.8日均线上拐。 2.收盘价上穿8日均线。
公式在线网解答:
m8:=ma(c,8);
xg:cross(c,m8) and m8>ref(m8,1);
评论(0)