通达信妖股资金异动主图/选股预警指标公式源码

已将主图中的妖股和资金异动信号分别做了选股预警公式,分享有需要的朋友学习

AAA:=(3*C+H+L+O)/6;
VAR1:=(8*AAA+7*REF(AAA,1)+6*REF(AAA,2)+5*REF(AAA,3)+4*REF
(AAA,4)+3*REF(AAA,5)+2*REF(AAA,6)+REF(AAA,8))/36,COLORFF7700;
VAR2:=(HHV(VAR1,5)+HHV(VAR1,10)+HHV(VAR1,20))/3;
VAR3:=(LLV(VAR1,5)+LLV(VAR1,10)+LLV(VAR1,20))/3;
VAR4:=(HHV(VAR2,5)+HHV(VAR2,10)+HHV(VAR2,20))/3;
VAR5:=(LLV(VAR3,5)+LLV(VAR3,10)+LLV(VAR3,20))/3;
VAR6:=(LLV(VAR1,2)+LLV(VAR1,4)+LLV(VAR1,6))/3;
{行业属性}
Z1:=STRCAT(HYBLOCK,' ');
Z2:=STRCAT(Z1,DYBLOCK);
Z3:=STRCAT(Z2,' ');
DRAWTEXT_FIX(ISLASTBAR,0,0,0,STRCAT(Z3,GNBLOCK)),COLORLIRED;
DA:(3*CLOSE+OPEN+LOW+HIGH)/6,POINTDOT;
X2:(20*DA+19*REF(DA,1)+18*REF(DA,2)+
17*REF(DA,3)+16*REF(DA,4)+15*REF(DA,5)+14*REF(DA,6)+13*REF(DA,7)+12*REF(DA,8)
+11*REF(DA,9)+10*REF(DA,10)+9*REF(DA,11)+8*REF(DA,12)+7*REF(DA,13)+6*REF(DA,14)+5*
REF(DA,15)+4*REF(DA,16)+3*REF(DA,17)+2*REF(DA,18)+REF(DA,20))/210,COLOR141414,NODRAW;
X3:MA(X2,5),LINETHICK2,COLORGREEN;
MAA5:MA(C,5),COLORRED,LINETHICK2;
MAA10:=MA(C,10);
MAA30:MA(C,30),COLORRED,NODRAW;
MA5:MA(CLOSE,5);
MA10Q:MA(CLOSE,10),NODRAW;
MA20Q:MA(CLOSE,20),NODRAW;
MA60Q:MA(CLOSE,60),NODRAW;


AA1E:=AMOUNT/V;
BB1E:=L<AA1E*0.9;
CC1E:=(C-REF(C,1))/REF(C,1)*100>1.2;
DD1E:=L<MA(C,5)*0.921;
EE1E:=V<MA(V,5)*1.5;
资金异动:=BB1E AND CC1E AND DD1E AND EE1E,LINETHICK0;
DRAWTEXT(资金异动,(LOW* 0.98),'↖资金异动'),COLOR40CCFF;


MA5A:MA(CLOSE,5),NODRAW;
MA10A:MA(CLOSE,10),NODRAW;
MA20A:MA(CLOSE,20),NODRAW;
MA30A:MA(CLOSE,30),NODRAW;
MA54A:=MA(CLOSE,54),NODRAW;
MA60A:MA(CLOSE,60),NODRAW;
MA120A:MA(CLOSE,120),NODRAW;
HJ_8:=(REF(CLOSE,3)-CLOSE)/REF(CLOSE,3)*100>5;
HJ_9:=FILTER(HJ_8,10);
HJ_10:=BARSLAST(HJ_9);
HJ_11:=REF(HIGH,HJ_10+2);
HJ_12:=REF(HIGH,HJ_10+1);
HJ_13:=REF(HIGH,HJ_10);
HJ_14:=MAX(HJ_11,HJ_12);
HJ_15:=MAX(HJ_14,HJ_13);
HJ_16:=(CLOSE-REF(CLOSE,1))/REF(CLOSE,1)*100>5;
HJ_17:=HJ_10<150;
HJ_18:=(OPEN-HJ_15)/HJ_15*100<30;
HJ_19:=(CLOSE-LLV(LOW,HJ_10))/LLV(LOW,HJ_10)*100<50;
HJ_20:=(CLOSE-REF(OPEN,5))/REF(OPEN,5)*100<30;
HJ_21:=VOL/MA(VOL,5)<3.5;
HJ_22:=(CLOSE-REF(CLOSE,89))/REF(CLOSE,89)*100<80;
HJ_25:=HJ_16 AND HJ_17 AND HJ_18 AND HJ_19 AND HJ_20 AND HJ_21 AND HJ_22;
暴利:=FILTER(HJ_25,15);
PL1:=(((CLOSE-MA54A)/MA54A)<0.1);
PL2:=(((CLOSE-MA10A)/MA10A)<0.3);
偏离率:=(((PL1=1) AND (PL2=1))*0.2);
平台突破:=((((偏离率=0) AND (REF(偏离率,1)=0.2)) AND (REF((COUNT((偏离率=0.2),10)=10),1)=1))*-0.1);
妖股突破:=平台突破=-0.1;
XDF:=(暴利 OR 妖股突破);
VARA:=DMA(AMOUNT/VOL/100,VOL/CAPITAL);
VARAA:=DYNAINFO(7)/(REF(CLOSE,1))>1.05 AND (DYNAINFO(7)/O>1.05);
FLIGA:=(VOL/REF(VOL,1)>1.2 AND COUNT(CLOSE>OPEN,1)) OR (LOW>REF(HIGH,1) AND COUNT(OPEN>CLOSE,1) AND VOL/REF(VOL,1)>1.2);
妖股:XDF AND C/REF(C,1)>1.095 AND FLIGA AND VARAA,NODRAW;
DRAWICON(妖股,LOW*0.995,7);
DRAWTEXT(妖股,LOW*0.975,' ↖妖股'),COLORYELLOW;
{强势杀入
参数:
N 1 20 10
ZF 1 10 5}

BDGD:=C=HHV(C,N);
GDSJ:=BARSLAST(BDGD);
底:LLV(L,N),COLORFF9933,LINETHICK1,CROSSDOT,NODRAW;
顶:HHV(H,N),COLOR0099CC,LINETHICK1,CROSSDOT,NODRAW;
前高:IF(GDSJ>0,REF(C,GDSJ),REF(C,GDSJ)),COLORFFFF00,POINTDOT,LINETHICK2,NODRAW;
MA5S:MA(C,5),LINETHICK2,COLORFF00FF,NODRAW;
MA13S:MA(C,13),LINETHICK2,COLOR00FF00,NODRAW;
MA20S:=MA(C,20);
MA30S:=MA(C,30);
MA60S:=MA(C,60);
MA120S:=SMA(C,120,1);
TP:=CROSS(C,REF(前高,1));
出击:=TP AND COUNT(TP,5)=1;
TPSJ:=BARSLAST(出击);
HC:=CROSS(REF(前高,TPSJ+1),L) OR CROSS(REF(前高,TPSJ),C);
回踩:=HC AND TPSJ>1;
MTM:=C-REF(C,1);
DX:=100*EMA(EMA(MTM,6),6)/EMA(EMA(ABS(MTM),6),6);
放量上涨:=CLOSE/REF(CLOSE,1)>=1.01 AND VOL/REF(VOL,1)>=1.5 AND VOL>MA(VOL,5) AND REF(VOL,1)/REF(MA(VOL,5),1)<=1.8;
箱体形成:=((HHV(C,3)/LLV(C,N)-1)*100<=ZF AND (HHV(C,N)/LLV(C,3)-1)*100<=ZF)*0.3;
接近箱顶:=(CLOSE/REF(HHV(CLOSE,N),2)<=1.02 AND HIGH/REF(HHV(CLOSE,N),2)>=0.98)*0.5;
P1:=BARSLAST(箱体形成);
P2:=BARSLAST(接近箱顶);
期待突破:=(放量上涨 AND 接近箱顶 AND P1<=3 AND P2<=1)*2;
关注:=(放量上涨 AND 接近箱顶)*1;
ZH520:=ABS(MA5S-MA20S)/MA20S*100<=N;
ZH530:=ABS(MA5S-MA30S)/MA30S*100<=N;
QSXS1:=MA5>REF(MA5S,1);
QSXS2:=MA20S>REF(MA20S,1);
QSXS3:=MA30S>REF(MA30S,1);
DTPL:=MA20S>MA30S AND MA30S>MA120S;
LYHT:=DTPL AND QSXS2 AND QSXS3 AND NOT(QSXS1) AND REF(QSXS1,1);
老鸭回头:=LYHT*50;
WR5:=100*(HHV(H,5)-C)/(HHV(H,5)-LLV(L,5));
WR6:=100*(HHV(H,6)-C)/(HHV(H,6)-LLV(L,6));
WR:=80-(WR5*3+WR6*2)/5;
坑:=IF(WR<0,WR,0);
LYT:=DTPL AND QSXS2 AND QSXS3 AND COUNT(QSXS1,4)<=1;
GJHS:=C>MA5 AND ((QSXS1 AND NOT(REF(QSXS1,1))) OR C>REF(C,3));
LYKK:=GJHS AND (ZH520 OR ZH530) AND LYT;
买:=(LYKK AND NOT(REF(LYKK,1)))*50;
买1:=IF(LLV(DX,2)=LLV(DX,7) AND COUNT(DX<0,2) AND CROSS(DX,MA(DX,2)),1,0);
卖1:=IF(HHV(DX,2)=HHV(DX,7) AND COUNT(DX>50,2) AND CROSS(MA(DX,2),DX),1,0);
VARC:=SMA(MAX(C-REF(C,1),0),6,1)/SMA(ABS(C-REF(C,1)),6,1)*100;
VAR6S:=REF(C,1);
VAR7:=SMA(MAX(C-VAR6S,0),6,1)/SMA(ABS(C-VAR6S),6,1)*100;
优选:=(买 AND COUNT((MA13S>MA20S),5)=5)*100;
{以下设置主图显示方式}
{DRAWTEXT(老鸭回头,(MA13+MA20)/2, '○');
DRAWTEXT(WR<0,L*0.99, '#'),COLORYELLOW;
DRAWTEXT(WR<-10,L*0.99, '#'),COLORWHITE;
STICKLINE(买,H,L,1,0),COLOR00FF00,LINETHICK2;
STICKLINE(买,O,C,3,1),COLOR00FF00,LINETHICK2;}
DRAWTEXT(买>0,L*0.99, ' '),COLORRED;

DRAWICON(CROSS(82,VARC),HIGH,2);
DRAWTEXT(CROSS(84,VAR7),H*1.01,'顶'),COLORFFFF00;
 




未来函数检测结果如下:
该公式包含未来函数:CAPITAL
该公式包含未来函数:DYNAINFO
解密、定制、编写股票指标请联系QQ或微信同号:88652583
相关股票指标公式

联系我们  |  股票指标网  |  指标网   |  指标公式  |   加入收藏   |  设为主页

@2005-2023 粤ICP备2023063687号-2 股票指标网别名指标网仅为互联网文章,所有股票指标公式及文章仅供学习研究,并不构成投资建议,请勿以此为依据进行股票交易,由此引起的投资亏损与本站无关。股票指标网均来源互联网收集整理,如不慎侵犯了你的权益,请联系我们告知,我们将做删除处理
QQ:88652583 微信 88652583
sitemap站点地图