通达信副图指标简介:
长阳起爆点副图指标通过多个条件筛选出潜在的股价起爆点。代码中包含了计算不同周期的指数移动平均线(EMA),并结合价格变动、成交量、以及EMA之间的交叉关系来确定买入信号。此外,还使用了过滤函数来确保信号的稳定性,并通过绘制不同颜色的竖线和图标来直观地标示出起爆点,帮助交易者做出决策。
指标效果图:
EMA13:=EMA(C,13);{计算13日指数移动平均线}
EMA34:=EMA(C,34);{计算34日指数移动平均线}
EMA55:=EMA(C,55);{计算55日指数移动平均线}
EMA120:=EMA(C,120);{计算120日指数移动平均线}
ACB1:=(C-REF(C,1))/REF(C,1)*100>0.5;{收盘价相比前一日收盘价上涨超过0.5%}
ACB2:=V>MA(V,5)*0.6;{成交量大于5日均量的0.6倍}
ACB3:=COUNT(CROSS(EMA13,EMA55),3)=1;{最近3日内EMA13上穿EMA55}
ACB4:=ABS(EMA34-EMA55)/EMA55< 0.03;{EMA34与EMA55之差的绝对值占EMA55的比例小于0.03}
ACB5:=EMA55<=EMA120 AND EMA55>=REF(EMA55,1);{EMA55小于等于EMA120且不低于前一日EMA55}
峰火:=FILTER(ACB1 AND ACB2 AND ACB3 AND ACB4 AND ACB5,5);{过滤满足所有条件的股票}
起爆666:FILTER(峰火>=1,5);{进一步过滤,只保留峰火信号持续5天的股票}
起爆:=DATE=DATE;{公式网WWW.GUKOUDAI.COM}{判断日期是否相同,用于过滤}
STICKLINE(起爆666,0,100,9999,0)*起爆,COLOR000000;{绘制黑色竖线}
STICKLINE(起爆666,50,100,2,0)*起爆,COLOR0000FF;{绘制蓝色竖线}
STICKLINE(起爆666,60,100,4,0)*起爆,COLOR0000FF;{绘制蓝色竖线}
STICKLINE(起爆666,70,100,6,0)*起爆,COLOR0000FF;{绘制蓝色竖线}
STICKLINE(起爆666,80,100,7,0)*起爆,COLOR0000FF;{绘制蓝色竖线}
STICKLINE(起爆666,90,100,8,0)*起爆,COLOR0000FF;{绘制蓝色竖线}
STICKLINE(起爆666,70,100,1,0)*起爆,COLOR00FFFF;{绘制青色竖线}
STICKLINE(起爆666,80,100,2,0)*起爆,COLOR00FFFF;{绘制青色竖线}
STICKLINE(起爆666,90,100,3,0)*起爆,COLOR00FFFF;{绘制青色竖线}
STICKLINE(起爆666,35,45,9,0)*起爆,COLOR00FFFF;{绘制青色竖线}
DRAWTEXT(起爆666,起爆666*50,' ←启爆火焰'),COLOR0000FF;{在启爆火焰处绘制文本}
ABC0:=(CLOSE-LLV(LOW,60))/(HHV(HIGH,60)-LLV(LOW,60))*100;{计算60日价格相对位置}
ABC3:=SMA(ABC0,3,1);{计算ABC0的3日移动平均}
ABC1:=SMA(ABC3,4,1)-10,NODRAW;{计算ABC3的4日移动平均并减去10,不绘制}
ABC4:=(HHV(HIGH,60)-CLOSE)/(HHV(HIGH,60)-LLV(LOW,60))*100;{计算60日价格相对位置}
ABC5:=SMA(ABC4,3,1);{计算ABC4的3日移动平均}
ABC2:=SMA(ABC5,4,1)-90;{计算ABC5的4日移动平均并减去90}
STICKLINE(REF(ABC1,1)< ABC1,ABC1,REF(ABC1,1),3,0),COLOR0000FF;{绘制蓝色上升竖线}
STICKLINE(REF(ABC1,1)>ABC1,ABC1,REF(ABC1,1),3,0),COLOR00FF00;{绘制绿色下降竖线}
STICKLINE(FILTER(起爆666>=1,5),45,0,4,0),COLORRED;{绘制红色竖线}
DRAWTEXT(FILTER(起爆666=1,5),36,'起爆点'),COLORRED;{在起爆点处绘制红色文本}
STICKLINE(起爆666,40,25,1,0),COLORYELLOW;{绘制黄色竖线}
STICKLINE(起爆666,25,10,2,0),COLOR00FF00;{绘制绿色竖线}
STICKLINE(起爆666,10,0,3,0),COLORBLUE;{绘制蓝色竖线}
STICKLINE(起爆666,25,15,5,0),COLORRED;{绘制红色竖线}
STICKLINE(起爆666,15,6,4,0),COLORLIGREEN;{绘制浅绿色竖线}
STICKLINE(起爆666,6,0,6,0),COLORGREEN;{绘制绿色竖线}
STICKLINE(起爆666,30,10,4,1),COLORMAGENTA;{绘制洋红色竖线}
STICKLINE(起爆666,6,2,2.5,1),COLORYELLOW;{绘制黄色竖线}
STICKLINE(起爆666,2,36,3.5,1),COLORYELLOW;{绘制黄色竖线}
STICKLINE(起爆666,10,20,3,1),COLORMAGENTA;{绘制洋红色竖线}
DRAWICON(起爆666,21,32);{在起爆666处绘制图标}
DRAWICON(起爆666,25,26);{在起爆666处绘制图标}
DRAWICON(起爆666,30,28);{在起爆666处绘制图标}
DRAWICON(起爆666,18,28);{在起爆666处绘制图标}
DRAWICON(起爆666,15,28);{在起爆666处绘制图标}
DRAWICON(起爆666,20,10);{在起爆666处绘制图标}
DRAWICON(起爆666,10,28);{在起爆666处绘制图标}
DRAWICON(起爆666,6.6,29);{在起爆666处绘制图标}
DRAWTEXT(起爆666,26,'【启动点】'),COLORMAGENTA;{在启动点处绘制洋红色文本}
STICKLINE(IF(起爆666,-10,0),+38,3,2.2,0),COLOR990099;{绘制紫色竖线}
STICKLINE(IF(起爆666,-120,0),+39,0,2.6,0),COLORBB00BB;{绘制紫色竖线}
STICKLINE(IF(起爆666,-120,0),+39,0,2.1,0),COLORDD00DD;{绘制紫色竖线}
STICKLINE(IF(起爆666,-120,0),+36,0,3.0,0),COLOR003300;{绘制绿色竖线}
STICKLINE(IF(起爆666,-120,0),+36,0,2.4,0),COLOR005500;{绘制绿色竖线}
STICKLINE(IF(起爆666,-120,0),+33,0,3.0,0),COLOR005555;{绘制绿色竖线}
STICKLINE(IF(起爆666,-120,0),+33,0,3.4,0),COLOR007777;{绘制绿色竖线}
STICKLINE(IF(起爆666,-120,0),+33,0,1.8,0),COLOR009999;{绘制绿色竖线}
STICKLINE(IF(起爆666,-120,0),+33,0,1.2,0),COLOR00BBBB;{绘制绿色竖线}
STICKLINE(IF(起爆666,-120,0),+33,0,0.6,0),COLOR00DDDD;{绘制绿色竖线}
STICKLINE(起爆666,2,20,3.5,1),COLORYELLOW;{绘制黄色竖线}