通达信公式源码概况:

指标类别:通达信公式

授权方式: 免费版

指标评级: ★★★★★

指标分类: 策略

画线方法: 副图

一、通达信当日涨停指标公式

  

N:=10;  

突破平台:=REF(HHV(C,N),1)/LLV(C,N)<1.5ANDCROSS(CLOSE,REF(HHV(CLOSE,N),1));  

涨停:=C/REF(C,1)>1.095;  

JD:=ATAN(("MACD.DIF#WEEK"/REF("MACD.DIF#WEEK",1)-1)*100)*180/3.1416;  

前期上穿零:=EXIST(CROSS("MACD.DIF#WEEK","MACD.DEA#WEEK"),15)AND"MACD.DIF#WEEK">0;  

加速:=REF(JD,1)<40ANDJD>45;  

涨停突破平台:突破平台AND前期上穿零AND加速AND涨停;  

MA5:=MA(C,5);  

MA10:=MA(C,10);  

MA20:=MA(C,20);  

MA60:=MA(C,60);  

A:=MA5>MA10ANDMA10>MA20ANDMA20>MA60;  

XG:BETWEEN(C/O,0.99,1.01)ANDBETWEEN(C,MA10,MA5)ANDAANDC<O;  

IF(STRFIND(PERIODNAME,&quot;分钟&quot;,1)&gt;0)  

{  

统计:该指标只在日线、周线、月线、季线和年线周期下有效; 

RETURN;  

}  

r:=1000000*(ZDMCCS[-1]+BDMCCS[-1]-(ZDMRCS[-1]+BDMRCS[-1]))/(SHGZG/(VOL/VOLAMOUNT));  

散户数量:r;  

STICKLINE(r&gt;0,0,r,8),color00ff00;  

STICKLINE(r&lt;0,0,r,8),colorff00ff;  

r0:=1000000*(IF(ISNULL(ZDMCCS[-1]),0,ZDMCCS)+IF(ISNULL(BDMCCS[-1]),0,BDMCCS)  

-(IF(ISNULL(ZDMRCS[-1]),0,ZDMRCS)+IF(ISNULL(BDMRCS[-1]),0,BDMRCS)))  

/(SHGZG/(VOL/VOLAMOUNT));  

ma5:MA(r0,5);  

MA10:MA(r0,10);  

MA20:MA(r0,20);  

VAR1:=3;  

VAR2:=(3)*(SMA(((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27)))*(100),5,1))-(2)*(SMA(SMA(((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27)))*(100),5,1),3,1));  

股价启动在即:IF(CROSS(VAR2,VAR1),100,0),coloryellow;  

秘密买点:IF((VAR2<=3),25,0),COLORFF00FF;  

机构建增补仓:IF((VAR2<5),45,0),COLOR00FF00;  

A1:=REF(C,1);  

涨停:=IF((C-A1)*100/A1>=(10-0.01*100/A1),1,0);  

跌停:=IF((A1-C)*100/A1>=(10-0.01*100/A1),1,0);  

涨停次数:=COUNT(涨停,250);  

跌停次数:=COUNT(跌停,250);  

DRAWNUMBER(涨停,HIGH*1.04,涨停次数),COLORYELLOW;  

DRAWNUMBER(跌停,HIGH*1.04,跌停次数),COLORCYAN;  

DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.52,0.04,0,涨停次数),COLORYELLOW;  

DRAWNUMBER_FIX(CURRBARSCOUNT=1,0.62,0.04,0,跌停次数),COLORCYAN;  

DRAWTEXT_FIX(CURRBARSCOUNT=1,0.44,0.04,0,'上市以来共涨停:'),COLORYELLOW;  

DRAWTEXT_FIX(CURRBARSCOUNT=1,0.54,0.04,0,'上市以来共跌停:'),COLORCYAN;  

涨停K线:=IF((C-A1)*100/A1>=(10-0.01*100/A1),1,0);  

跌停K线:=IF((A1-C)*100/A1>=(10-0.01*100/A1),1,0);  

STICKLINE(涨停K线,OPEN,CLOSE,2.5,0),COLORYELLOW;  

STICKLINE(跌停K线,OPEN,CLOSE,2.5,0),COLORBLUE;  

DIF:=EMA(DCLOSE,12)-EMA(DCLOSE,26);  

DEA:=EMA(DIF,9);  

AAA:=(DIF-DEA)*2*60;  

启动:=CROSS(AAA-REF(AAA,1),15),COLORRED,LINETHICK2;  

DRAWTEXT(启动,L*0.98,'↖金牛启动'),COLORYELLOW,LINETHICK2;

image.png

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

ZT赋值:如果模糊匹配品种名称ORNAMELIKE('*ST'),返回收盘价=计算涨停价,否则返回如果模糊匹配品种代码OR(模糊匹配品种代码ANDDATE>=1200824),返回收盘价=计算涨停价,否则返回收盘价=计算涨停价

输出XG:统计10日中满足ZT的天数=2

每日通达信公式解答:


  

编写条件:  

5日前涨幅大于8%的选股公式。  

编写方法:  

AA:=(C/REF(C,1)-1)*100;  

XG:REF(AA,4)>8;


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