相关简介:通达信散户主力扫货机构游资指标公式源码分享
通达信指标公式源码概况:
指标类别:通达信指标公式
授权方式:免费版
指标评级:★★★★★
指标分类:策略
画线方法:副图
主力吸筹时的K线形态:
1、在个股股价的底部区域反复出现十字星、倒T字型和T字型,这些线不断出现,每天的收盘价大致相当,主力成本位于上、下线之间或稍高一点,这些K线的出现是十分明显的主力进货痕迹。
2、在底部区域以小阳线缓步推升,底部渐高,但这些阳线还没有达到足以引起人们注意的程度,当主力以大量和大阳拉起股价时,人们才如梦初醒。
主力吸筹形态有哪些?
1、舍线腾空。是指在经过连续的缩量单边下行调整之后,在无重大利好消息的刺激下,股价突然大幅高开,一般当天收盘情况分为二种。高开收阴,不补缺口,则当天的低点或第二天开盘的低点是最佳介入点;高开收阳,则冲高后再次回落到舍线位时为最佳低吸点,随之而来的是调整结束后的中线上升行情,是常见的主力吸筹形态之一。
通达信指标公式源码:
STICKLINE(C,90,90,0.9,0.9),COLOR883333;
STICKLINE(C,10,10,0.9,0.9),COLOR883333;
散户:=100*(HHV(HIGH,60)-CLOSE)/(HHV(HIGH,60)-LLV(LOW,60));
RSV:=(CLOSE-LLV(LOW,30))/(HHV(HIGH,30)-LLV(LOW,30))*100;
RSV1:=(C-MA(C,4))/MA(C,4)*100;
VAR2:=REF(LOW,1);
VAR3:=SMA(ABS(LOW-VAR2),3,1)/SMA(MAX(LOW-VAR2,0),3,1)*100;
VAR4:=EMA(IF(CLOSE*1.3,VAR3*10,VAR3/10),3);
VAR5:=LLV(LOW,30);
VAR6:=HHV(VAR4,30);
VAR7:=IF(MA(CLOSE,58),1,0);
VAR8:=EMA(IF(LOW<=VAR5,(VAR4+VAR6*2)/2,0),3)/618*VAR7;
VAR9:=IF(VAR8>100,100,VAR8);
K:=SMA(RSV,5,1);
D:=SMA(K,3,1);
J:=3*K-2*D;
主力:=EMA(J,6),COLORYELLOW;
AA3:=(HHV(HIGH,21)-CLOSE)/(HHV(HIGH,21)-LLV(LOW,21))*100-10;
AA4:=(CLOSE-LLV(LOW,21))/(HHV(HIGH,21)-LLV(LOW,21))*100;
AA5:=SMA(AA4,13,8);
走势:=CEILING(SMA(AA5,13,8)),COLORRED,LINETHICK2;
AA6:=SMA(AA3,21,8);
买观注:STICKLINE(走势-AA6<-65,0,7,15,1);
DRAWICON(FILTER(J>REF(J,1)AND走势>=REF(走势,1)AND走势<25,5),走势,1);
卖观注:STICKLINE(走势-AA6>85,98,90,15,1),COLORFFFF00;
DRAWICON(FILTER(J<REF(J,1)AND走势<=REF(走势,1)ANDJ>85,5),J,2);
吸筹:STICKLINE(VAR9>-120,50,50+(VAR9/2),8,1),COLORRED;
CDMA:EMA(EMA(RSV1,7),7)*8,NODRAW,COLORWHITE;
STICKLINE(CDMA>=0ANDCDMA>=REF(CDMA,1),50,50+CDMA,2.5,0),COLORDD55CC;
STICKLINE(CDMA>=0ANDCDMA<=REF(CDMA,1),50,50+CDMA,2.5,1),COLORDD55CC;
STICKLINE(CDMA<=0ANDCDMA>=REF(CDMA,1),50,50+CDMA,2.5,1),COLOR00D080;
STICKLINE(CDMA<=0ANDCDMA<=REF(CDMA,1),50,50+CDMA,2.5,0),COLOR00D080;
快线:(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100,LINETHICK2,COLOR333333;
散户线:散户,COLORFFFFFF,LINETHICK1;
主力线:主力,COLORYELLOW;
走势线:走势,COLORRED,LINETHICK3;
DRAWTEXT(ISLASTBAR,散户线,’←散户线’),COLORFFFFFF;
DRAWTEXT(ISLASTBAR,主力线,’←主力线’),COLORYELLOW;
DRAWTEXT(ISLASTBAR,走势线,’←走势线’),COLORRED;
关注低买:IF(90>散户ANDCROSS(90,散户),98,0),COLORMAGENTA,STICK,NODRAW;
{高抛低吸:IF(散户<10ANDCROSS(10,散户),20,0),COLORGREEN,STICK,NODRAW;}
风险:COUNT(“rsi.RSI1″(6,12,24)>80,3)=3ANDCROSS(“RSI.RSI2″(6,12,24),79.5),NODRAW;
观注顶:(散户<8AND主力>90AND走势>90ANDCDMA<=REF(CDMA,1)AND散户线),COLORGREEN,NODRAW;
DRAWTEXT(观注顶,-1,’◆’),COLORGREEN;
DRAWTEXT(风险,95,’←风险’),COLOR00FFFF;
STICKLINE(关注低买,0,100,0,-1),COLORMAGENTA;
{STICKLINE(高抛低吸,0,100,0,-1),COLORGREEN;};
M1:=EMA(C,5);M2:=EMA(C,13);M3:=EMA(C,34);
MC1:=EMA(C,55);MC2:=EMA(C,89);MA4:=EMA(C,144);
判势线:=NEWSAR(1,100),COLORYELLOW,LINETHICK2;
牛熊线:IF(MC1>MAX(MC2,MA4),MC1,IF(MC1<MIN(MC2,MA4),MC2,MA4)),COLORFF00CC,LINETHICK2;
AA:=1;
中轨:EMA(CLOSE,17)*AA,LINETHICK1,COLORFFFFFF;
卖出线:中轨+2*STD(CLOSE,17),LINETHICK1,COLOR0000FF;
买入线:中轨-2*STD(CLOSE,17),LINETHICK1,COLOR00CC00;
清仓线:中轨+3*STD(CLOSE,17),LINETHICK1,COLORFF00FF;
满仓线:中轨-3*STD(CLOSE,17),LINETHICK1,COLOR00AA00;
LOCK:=IF(TIME<1160101,1,0);
VARA:=MA(CLOSE,20);
趋势线:IF(VARA>REF(VARA,2),VARA,IF(VARA<REF(VARA,2),VARA,VARA)),COLOR00FF00;
IF(VARA>REF(VARA,2),VARA,DRAWNULL),LINETHICK2,COLORFF00FF;
IF(VARA=REF(VARA,2),VARA,DRAWNULL),LINETHICK2,COLORFF0000;
IF(VARA<REF(VARA,2),VARA,DRAWNULL),LINETHICK2,COLOR00FF00;
买入:IF(VARA>REF(VARA,2)ANDREF(VARA<=REF(VARA,2),1),1,0),NODRAW,COLORAAAAAA;
DRAWICON(CROSS(LOW,满仓线),满仓线*0.96,11);
DRAWICON(CROSS(HIGH,清仓线),HIGH,12);
TY:=CLOSE;
A1:=REF(TY,10)=HHV(TY,2*10+1);B1:=FILTER(A1,10);C1:=BACKSET(B1,10+1);HD:=FILTER(C1,10);
A2:=REF(TY,10)=LLV(TY,2*10+1);B2:=FILTER(A2,10);C2:=BACKSET(B2,10+1);LD:=FILTER(C2,10);
A:=REF(CLOSE,BARSLAST(HD));B:=REF(CLOSE,BARSLAST(LD));
T1:=BARSLAST(HD)<BARSLAST(LD)ANDNOT(HD);
T2:=BARSLAST(HD)>BARSLAST(LD)ANDNOT(LD);
波峰:IF(T1,A,A),COLORFF00FF,POINTDOT;
STICKLINE(T1,A,A,1.5,0),COLORFF00FF;
波谷:IF(T2,B,B),COLOR80FF00,POINTDOT;
STICKLINE(T2,B,B,1.5,0),COLOR80FF00;
MA1:=MA(C,3);
XG1:=MA1>REF(MA1,1)ANDREF(MA1,1)<REF(MA1,2)ANDC>MA(C,7);
DRAWTEXT(FILTER(XG1,9),LOW*0.97,’B’),COLORRED,LINETHICK2;
DRAWICON(FILTER(XG1,9),LOW*0.98,1);
VAR2:=SUM(IF(CLOSE>OPEN,vol,0),30)/SUM(VOL,30)*100;
VAR3:=100-SUM(IF(CLOSE>OPEN,VOL,0),30)/SUM(VOL,30)*100;
多头力量:=VAR2;
空头力量:=VAR3;
RSV:=(CLOSE-LLV(LOW,18))/(HHV(HIGH,18)-LLV(LOW,18))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
XG2:=多头力量>空头力量AND多头力量-空头力量>30ANDCROSS(D,K)OR
MA1<REF(MA1,1)ANDREF(MA1,1)>REF(MA1,2)ANDREF(MA1,2)>REF(MA1,3)ANDK>50;
DRAWTEXT(FILTER(XG2,9),H*1.06,’S’),COLORGREEN,LINETHICK2;
DRAWICON(FILTER(XG2,9),H*1.02,2);
{跳空缺口}
LL1:=REF(L,1);
HH1:=REF(H,1);
SQK:=L>HH1;
XQK:=H<LL1;
上跳:IF(SQK=1,L-HH1,DRAWNULL),COLORFF00FF,CROSSDOT,LINETHICK3,NODRAW;
下跳:IF(XQK=1,H-LL1,DRAWNULL),COLORGREEN,CROSSDOT,LINETHICK3,NODRAW;
STICKLINE(SQK,L,HH1,4*1,1),COLORYELLOW;{上跳}
STICKLINE(XQK,H,LL1,4*1,2),COLOR00FF00;{下跳}
DRAWTEXT(SQK,H,’上跳’),COLORYELLOW;
DRAWTEXT(XQK,L,’下跳’),COLOR00FF00;
{补缺口}
K1:=BARSLAST(L>REF(H,1));
K2:=L<REF(H,K1+1)ANDCOUNT(L<REF(H,K1+1),K1)=1;
STICKLINE(K2,L,O,1,0),COLORFF00FF;{缺口回补};
DRAWTEXT(K2=1,L,’回补’),COLORFF00FF;
AA:=crOSS(ma(C,5),MA(C,20))ANDCROSS(MA(C,5),MA(C,30))ANDCROSS(MA(C,5),MA(C,60));
BBB:=MA(C,60)>MA(C,10)ANDCROSS(MA(C,10),MA(C,30))ANDMA(C,30)>MA(C,20)ANDAbs(MA(C,60)-MA(C,20))/MA(C,20)<0.05;
CCC:=MA(C,30)>MA(C,5)ANDCROSS(MA(C,5),MA(C,20))ANDMA(C,20)>MA(C,10);
DD:=ABS((MA(C,5)-MA(C,10))+(MA(C,10)-MA(C,20))+(MA(C,20)-MA(C,30)))<0.02ANDMA(C,5)>REF(MA(C,5),1)ANDMA(C,10)>REF(MA(C,10),1);
EE:=MA(C,20)>MA(C,5)ANDCROSS(MA(C,5),MA(C,10))ANDMA(C,10)>MA(C,60)ANDABS(MA(C,20)-MA(C,60))/MA(C,60)<0.05;
FF:=AAORBBBORCCCORDDOREE;
探测:=FFANDFILTER(FF,8);
DRAWTEXT(探测,L*0.958,’●(BUY)’),COLORRED;
stICKLINE(探测,H,L,0.3,0),COLORRED;
STICKLINE(探测,O,C,5,0),LINETHICK2,COLORRED;
AA1:=AMOUNT/vol;
BB1:=L1.2;
DD1:=L<MA(C,5)*0.921;
EE1:=VOL<MA(V,5)*1.5;
FF1:=BB1ANDCC1ANDDD1ANDEE1,COLORRED,LINETHICK0;
DRAWTEXT(FF1,L*0.99,’●(潜伏)’),COLORYELLOW;
STICKLINE(FF1,H,L,0.3,0),COLORYELLOW;
STICKLINE(FF1,O,C,5,0),LINETHICK2,COLORYELLOW;
DRAWTEXT(CROSS((REF(HIGH,1)+REF(LOW,1))/2,MA(CLOSE,20)+2*STD(CLOSE,20)),
HIGH*1.02,’●警’),COLORGREEN;
N:=5;
E:=(HIGH+LOW+OPEN+2*CLOSE)/5;
AAA:=2*E-LOW,NODRAW;AB:=2*E-HIGH,NODRAW;
acC:=E+(HIGH-LOW),NODRAW;ADD:=E-(HIGH-LOW),NODRAW;今阻力:REF(AAA,1),COLORWHITE,NODRAW;
今支撑:REF(AB,1),COLORYELLOW,NODRAW;
明阻力:AAA,COLORCYAN,NODRAW;
明支撑:AB,COLORMAGENTA,NODRAW;
明突破:ACC,COLORGREEN,NODRAW;
明反转:ADD,COLORLICYAN,NODRAW;
{压力+支撑}
压力:MA(REF(HHV(C,30),1),2),COLORBLACK;
支撑:MA(REF(LLV(C,30),1),2),COLORBLACK;
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,COLORRED;
马线:MA(牛线,6),COLORGREEN;
MAA5:MA(C,5),COLORFF00FF,LINETHICK2;
A3:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;
A4:=SMA(A3,3,1);
A5:=SMA(A4,3,1);
A6:=3*A4-2*A5;
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));
STICKLINE(买,OPEN,CLOSE,2,0),COLORYELLOW;
LC:=REF(CLOSE,1);
rsi:=((SMA(MAX((CLOSE-LC),0),3,1)/SMA(ABS((CLOSE-LC)),3,1))*100);
FF2:=EMA(CLOSE,3);
MA15:=EMA(CLOSE,21);
日:=150;昨前:=3;
高1:=REF(HHV(H,日),昨前);
低1:=REF(LLV(L,日),昨前);
H1:=高1-(高1-低1)*0.191;
H2:=高1-(高1-低1)*0.382;
H3:=高1-(高1-低1)*0.5;
H4:=高1-(高1-低1)*0.618;
H5:=高1-(高1-低1)*0.809;
顶:REFDATE(高1,DATE),COLORRED;
一0809:REFDATE(H1,DATE),COLORYELLOW;
二0618:REFDATE(H2,DATE),COLORMAGENTA;
三0500:REFDATE(H3,DATE),COLORWHITE;
四0382:REFDATE(H4,DATE),COLORGREEN;
五0191:REFDATE(H5,DATE),COLORYELLOW;
低:REFDATE(低1,DATE),COLORRED;
[源码注释]通达信公式动态翻译结果
AA赋值:最高价<1日前的最低价
BB赋值:上次AA距今天数
输出XG:BB<=5 AND 最高价>BB+1日前的最低价上穿0.5
评论(0)