以下是超牛龙头,信号发出必有一大行情公式指标源码和截图
超牛龙头,信号发出必有一大行情公式指标源码:
N1:=5;
N2:=10;
LC:=REF(CLOSE,1);
A0:=(2*C+H+L)/4;
:=ma(A0,3) REF(MA(A0,3),1);
安全线:2,COLORRED,POINTDOT,LINETHICK4;
A1:=(CLOSE-LLV(LOW,7))/(HHV(HIGH,7)-LLV(LOW,7))*10;
K:MA(3*SMA(A1,6,1)-2*SMA(SMA(A1,5,1),5,1),3),LINETHICK1,COLORF00FF0;
D:MA(K,3),COLORFF0000,LINETHICK1;
J:3*K-2*D,LINETHICK1,COLORF00FF0;
DRAWBAND(K,RGB(155,50,50),D,RGB(0,100,50));
VAR1:=C-REF(C,1);
VAR2:=100*EMA(EMA(VAR1,6),6)/EMA(EMA(Abs(VAR1),6),6);
MA5:=EMA(C,5);
MA13:=EMA(C,13);
UP:=DRAWLINE(L=LLV(L,BArslAst(crOSS(MA13,MA5))+1),LLV(L,BARSLAST(CROSS
(MA13,MA5))+1),H=HHV(H,BARSLAST(CROSS(MA5,MA13))+1),HHV(H,BARSLAST(CROSS
(MA5,MA13))+1),0),COLOR0000FF;
DOWN:=DRAWLINE(H=HHV(H,BARSLAST(CROSS(MA5,MA13))+1),HHV(H,BARSLAST(CROSS
(MA5,MA13))+1),L=LLV(L,BARSLAST(CROSS(MA13,MA5))+1),LLV(L,BARSLAST(CROSS
(MA13,MA5))+1),0),COLOR00FF00;
BT:=(LLV(VAR2,2)=LLV(VAR2,7)ANDCOUNT(VAR2 0,2)ANDCROSS(VAR2,MA(VAR2,2)))AND
REF(DOWN,1) REF(DOWN,2)ANDUP REF(DOWN,1);
底线:0,COLORFF00FF;
顶线:10,COLORFF0000;
STICKLINE(UP,0,0.2,3,0),COLOR0000FF;
STICKLINE(DOWN,0,0.2,3,0),COLOR00FF00;
STICKLINE(BT,0,3,2,0),COLOR000088;
STICKLINE(BT,0,3,1,0),COLOR0000CC;
STICKLINE(BT,0,3,0.22,0),COLOR0000FF;
DRAWTEXT(BT,3,'短牛'),COLOR0000FF;
TJ1:=REF(DOWN,1) REF(DOWN,2)ANDUP REF(DOWN,1)ANDC HHV(H,21)*0.82;
STICKLINE(TJ1,0,2,3,0),COLOR880088;
STICKLINE(TJ1,0,2,1.5,0),COLORAA00AA;
STICKLINE(TJ1,0,2,0.8,0),COLORCC00CC;
STICKLINE(TJ1,0,2,0.2,0),COLORFF00FF;
DRAWTEXT(TJ1,2,'中牛'),COLORFF00FF;
HR:=HHV(HIGH,55);
HRY:=LLV(LOW,55);
HRY11:=HR*HRY;
HRY33:=SQRT(HRY11);
TJ2:=REF(DOWN,1) REF(DOWN,2)ANDUP REF(DOWN,1)ANDC HRY33;
STICKLINE(TJ2,0,1,5,0),COLOR008888;
STICKLINE(TJ2,0,1,2,0),COLOR00AAAA;
STICKLINE(TJ2,0,1,1,0),COLOR00CCCC;
STICKLINE(TJ2,0,1,0.2,0),COLOR00FFFF;
DRAWTEXT(TJ2,1,'大牛'),COLOR00FFFF;
ST:=REF(UP,1) REF(UP,2)ANDDOWN REF(UP,1);
STICKLINE(ST,10,9,5,0),COLOR008800;
STICKLINE(ST,10,9,2,0),COLOR00AA00;
STICKLINE(ST,10,9,1,0),COLOR00CC00;
STICKLINE(ST,10,9,0.2,0),COLOR00FF00;
DRAWTEXT(ST,9,'卖'),COLOR00FF00;
DIFF:EMA(DCLOSE,12)-EMA(DCLOSE,26);
DEA:EMA(DIFF,9),COLORFFFF00;
A11:=BARSLAST(REF(CROSS(DIFF,DEA),1));
底:=REF(CLOSE,A11+1) CLOSEANDDIFF REF(DIFF,A11+1)ANDCROSS(DIFF,DEA);
DRAWTEXT(底背离,-0.6,'底背离'),COLORWHITE;
A22:=BARSLAST(REF(CROSS(DEA,DIFF),1));
顶背离:=REF(CLOSE,A22+1) CLOSEANDREF(DIFF,A22+1) DIFFANDCROSS(DEA,DIFF);
DRAWTEXT(顶背离,11,'顶背离'),COLORWHITE;
N:=9;
P:=14;
M:=26;
{指标}
个股涨幅:(C-REF(C,1))/REF(C,1)*100,COLORRED,NODRAW;
行业涨幅:(HY_INDEXC-REF(HY_INDEXC,1))/REF(HY_INDEXC,1)*100,COLORYELLOW,NODRAW;
涨幅:(INDEXC-REF(INDEXC,1))/REF(INDEXC,1)*100,COLORCYAN,NODRAW;
A1:=MA(LLV(C,N)*1.1,P);
A2:=MA(HHV(C,M)*0.9,P);
DPC:=INDEXC;
A3:=MA(LLV(DPC,N)*1.1,P);
A4:=MA(HHV(DPC,M)*0.9,P);
HYC:=HY_INDEXC;
A31:=MA(LLV(HYC,N)*1.1,P);
A41:=MA(HHV(HYC,M)*0.9,P);
A5:=(A1+A2)/2;
A6:=(A3+A4)/2;
A61:=(A31+A41)/2;
A71:=C-A5-A5*(A61-EXPMEMA(HYC,3))/A61;{强于行业}
A7:=C-A5-A5*(A6-EXPMEMA(DPC,3))/A6;{强于大盘}
能量释放强大盘:=(A7 =0)*A7,COLORRED,NODRAW;
能量释放强行业:=(A71 =0)*A71,COLORYELLOW,NODRAW;
LTP:=C*CAPITAL/100,;{万股}
ER:=VOL/LTP;
A8:=ER 2ANDC OANDC MA(C,7)AND
MA(C,7) MA(C,37)ANDA7 -0.9ANDVOL MA(VOL,5);
{脉冲拉升:A8,COLORLIMAGENTA,NODRAW;
STICKLINE(A8,(A7 =0)*A7*1.7,0,0.8,-1)COLORLIMAGENTA;}
STICKLINE((A71 =0)*A71,(A7 =0)*A7*1.4,0,2,-1)COLORYELLOW;
STICKLINE((A71 0)*A71,(A7 0)*A7*1.4,0,2,-1)COLORCYAN;
STICKLINE((A7 0)*A7,0,(A7 0)*A7*1.2,3,0),COLOR779900;
STICKLINE((A7 0)*A7,0,(A7 0)*A7*1.2,2.2,0),COLOR77BB00;
STICKLINE((A7 0)*A7,0,(A7 0)*A7*1.2,1.5,0),COLOR77DD00;
STICKLINE((A7 0)*A7,0,(A7 0)*A7*1.2,0.5,0),COLOR77FF00;
STICKLINE((A7 =0)*A7,0,(A7 =0)*A7*1.2,3,0)COLOR000099;
STICKLINE((A7 =0)*A7,0,(A7 =0)*A7*1.2,2.2,0),COLOR0000BB;
STICKLINE((A7 =0)*A7,0,(A7 =0)*A7*1.2,1.5,0),COLOR0000DD;
STICKLINE((A7 =0)*A7,0,(A7 =0)*A7*1.2,0.5,0),COLOR0000FF;
DRAWRECTREL(487,5,999,999,0);
DRAWRECTREL(1,5,487,999,RGB(0,0,51));
{三强}
DRAWTEXT_FIX(ISLASTBAR,0.01,0.85,0,STRCAT(STRCAT('【情绪共振】',CON2STR(DRAWNULL,0)),'')),COLORWHITE;
DRAWTEXT_FIX(ISLASTBARAND个股涨幅 =行业涨幅,0.25,0.85,1,STRCAT(STRCAT('个股强',CON2STR(DRAWNULL,0)),'')),COLORRED;
DRAWTEXT_FIX(ISLASTBARAND个股涨幅 行业涨幅,0.25,0.85,1,STRCAT(STRCAT('个股弱',CON2STR(DRAWNULL,0)),'')),COLORCYAN;
DRAWTEXT_FIX(ISLASTBARAND大盘涨幅 =行业涨幅,0.35,0.85,1,STRCAT(STRCAT('行业强',CON2STR(DRAWNULL,0)),'')),COLORRED;
DRAWTEXT_FIX(ISLASTBARAND大盘涨幅 行业涨幅,0.35,0.85,1,STRCAT(STRCAT('行业弱',CON2STR(DRAWNULL,0)),'')),COLORCYAN;
DRAWTEXT_FIX(ISLASTBARANDREF(大盘涨幅,1) =大盘涨幅,0.45,0.85,1,STRCAT(STRCAT('大盘强',CON2STR(DRAWNULL,0)),'')),COLORRED;
DRAWTEXT_FIX(ISLASTBARANDREF(大盘涨幅,1) 大盘涨幅,0.45,0.85,1,STRCAT(STRCAT('大盘弱',CON2STR(DRAWNULL,0)),'')),COLORCYAN;
{基因}
DRAWTEXT_FIX(ISLASTBAR,0.01,0.75,0,STRCAT(STRCAT('【量能基因】今日量',CON2STR(V/10000,2)),'万')),COLORWHITE;
{个股行业大盘}
G今量比昨量:=V/REF(V,1);
D今量比昨量:=INDEXV/REF(INDEXV,1);
H今量比昨量:=HY_INDEXV/REF(HY_INDEXV,1);
JLZL1:=STRCAT('个股比昨:',CON2STR(G今量比昨量,2));
JLZL2:=STRCAT('行业比昨:',CON2STR(H今量比昨量,2));
JLZL3:=STRCAT('大盘比昨:',CON2STR(D今量比昨量,2));
ZTTJ0:=STRCAT(JLZL1,JLZL2);
ZTTJ1:=STRCAT(ZTTJ0,JLZL3);
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.19,0.75,0,ZTTJ1),COLORYELLOW;
{股性活跃}
%:=VOL/((FINANCE(7)-FINVALUE(244))/100)*100,NODRAW;
温和活跃:=IF(CAPITAL 500000,换手率% 7,IF(CAPITAL =500000ANDCAPITAL 1000000,换手率% 5,
IF(CAPITAL =1000000ANDCAPITAL 10000000,换手率% 3,
IF(CAPITAL =10000000ANDCAPITAL 50000000,换手率% 1,IF(CAPITAL =50000000,换手率% 0.5,DRAWNULL)))));
异动活跃:=IF(CAPITAL 500000,换手率% 7AND换手率% =10,IF(CAPITAL =500000ANDCAPITAL 1000000,换手率% 5AND换手率% =7,
IF(CAPITAL =1000000ANDCAPITAL 10000000,换手率% 3AND换手率% =5,
IF(CAPITAL =10000000ANDCAPITAL 50000000,换手率% 1AND换手率% =3,IF(CAPITAL =50000000,换手率% 0.5AND换手率% =1,DRAWNULL)))));
非常活跃:=IF(CAPITAL 500000,换手率% 10AND换手率% =14,IF(CAPITAL =500000ANDCAPITAL 1000000,换手率% 7AND换手率% =10,
IF(CAPITAL =1000000ANDCAPITAL 10000000,换手率% 5AND换手率% =7,
IF(CAPITAL =10000000ANDCAPITAL 50000000,换手率% 3AND换手率% =5,IF(CAPITAL =50000000,换手率% 1AND换手率% =3,DRAWNULL)))));
高度活跃:=IF(CAPITAL 500000,换手率% 14AND换手率% =20,IF(CAPITAL =500000ANDCAPITAL 1000000,换手率% 10AND换手率% =14,
IF(CAPITAL =1000000ANDCAPITAL 10000000,换手率% 7AND换手率% =10,
IF(CAPITAL =10000000ANDCAPITAL 50000000,换手率% 5AND换手率% =7,IF(CAPITAL =50000000,换手率% 3AND换手率% =5,DRAWNULL)))));
极度活跃:=IF(CAPITAL 500000,换手率% 20,IF(CAPITAL =500000ANDCAPITAL 1000000,换手率% 14,
IF(CAPITAL =1000000ANDCAPITAL 10000000,换手率% 10,
IF(CAPITAL =10000000ANDCAPITAL 50000000,换手率% 7,IF(CAPITAL =50000000,换手率% 5,DRAWNULL)))));
DRAWTEXT_FIX(ISLASTBAR,0.01,0.65,0,STRCAT(STRCAT('【股性活跃】真实换手',CON2STR(换手率%,2)),'%')),COLORWHITE;
DRAWTEXT_FIX(CURRBARSCOUNT=1AND温和活跃,0.20,0.65,0,'温和活跃'),COLORWHITE;
DRAWTEXT_FIX(CURRBARSCOUNT=1AND异动活跃,0.20,0.65,0,'异动活跃'),COLORYELLOW;
DRAWTEXT_FIX(CURRBARSCOUNT=1AND非常活跃,0.20,0.65,0,'非常活跃'),COLORLIRED;
DRAWTEXT_FIX(CURRBARSCOUNT=1AND高度活跃,0.20,0.65,0,'高度活跃'),COLORLIMAGENTA;
DRAWTEXT_FIX(CURRBARSCOUNT=1AND极度活跃,0.20,0.65,0,'极度活跃'),COLORRED;
{状态}
涨停:=IF(NAMELIKE('ST')ORNAMELIKE('*ST'),(C+0.01) ZTPRICE(REF(C,1),0.05),IF(CODELIKE('688')OR(CODELIKE('300')ANDDATE =1200824),(C+0.01) ZTPRICE(REF(C,1),0.2),
(C+0.01) ZTPRICE(REF(C,1),0.1)))ANDC=H;
ZTCS:=COUNT(涨停,BARSSINCE(涨停)+1);
DRAWTEXT_FIX(ISLASTBAR,0.01,0.55,0,STRCAT(STRCAT('【涨停状态】',CON2STR(DRAWNULL,0)),'')),COLORWHITE;
封单金额:=IF(FINANCE(3)==0,DRAWNULL,IF(GPJYVALUE(15,1,0)==2,GPJYVALUE(15,2,0),IF(GPJYVALUE(15,2,0)=0AND涨停,DYNAINFO(58)*DYNAINFO(20)*100/10000,0))),COLORYELLOW;
涨停溢价:=封单金额/(DYNAINFO(7)*CAPITAL*100/10000)*100;
涨停溢价高:=涨停AND涨停溢价
涨停溢价中:=涨停AND涨停溢价 5AND涨停溢价
涨停溢价低:=涨停AND涨停溢价
失控板1:=涨停ANDVOL HHV(REF(VOL,1),2)*2.1;
失控板2:=涨停AND(C-REF(C,2))/REF(C,2)*100
失控板:=失控板1AND失控板2;
加速板:=涨停ANDNOT(失控板)AND(VOL =REF(VOL,1)*0.7ORVOL =REF(VOL,2)*0.5);
分歧板:=涨停ANDNOT(失控板)ANDNOT(加速板);
DRAWTEXT_FIX(CURRBARSCOUNT=1AND失控板,0.20,0.55,0,'失控板'),COLORLIRED;
DRAWTEXT_FIX(CURRBARSCOUNT=1AND分歧板,0.20,0.55,0,'分歧板'),COLORLIMAGENTA;
DRAWTEXT_FIX(CURRBARSCOUNT=1AND加速板,0.20,0.55,0,'加速板'),COLORRED;
DRAWTEXT_FIX(CURRBARSCOUNT=1AND涨停溢价低,0.35,0.55,0,'涨停溢价低'),COLORLIRED;
DRAWTEXT_FIX(CURRBARSCOUNT=1AND涨停溢价中,0.35,0.55,0,'涨停溢价中'),COLORLIMAGENTA;
DRAWTEXT_FIX(CURRBARSCOUNT=1AND涨停溢价高,0.35,0.55,0,'涨停溢价高'),COLORRED;
B11:=BARSLASTCOUNT(涨停);
连续板:=(B11 1ANDREFX(NOT(涨停),1))OR(REF(涨停,1)AND涨停ANDISLASTBAR);
{DRAWTEXT(连续板,H*0.95,VARCAT(VAR2STR(B11,0),'天连板'))COLORYELLOW;}
DRAWTEXT_FIX(1AND连续板,0.30,0.55,1,STRCAT(STRCAT('【',CON2STR(B11,0)),'天连板】')),COLORRED;
超牛龙头,信号发出必有一大行情公式指标截图