股票软件通达信精品指标公式-金猪宝贝儿指标源码通达信公式
公式源码:
V0:=EMA(C,5),COLOR00FF66;
V1:EMA(C,10),COLOR00FF66;
V2:=EMA(C,15),POINTDOT,LINETHICK4,COLORFFFFFF;
V3:=EMA(C,30),POINTDOT,LINETHICK2;
V4:=EMA(C,60),POINTDOT,LINETHICK2,COLOR3366FF;
年线:EMA(C,90),COLORBLUE,POINTDOT,LINETHICK2;
M1:=1000*V1/V4<=1015 AND 1000*V1/V4>=975;
M2:=1000*V2/V4<=1020 AND 1000*V2/V4>=980;
M3:=1000*V3/V4<=1015 AND 1000*V3/V4>=985;
M4:=M1 AND M2 AND M3 AND CROSS(V0,V1);
M5:=M1 AND M2 AND M3 AND CROSS(V0,V3);
LC:=REF(CLOSE,1);
RSI:=SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100;
DRAWTEXT(CROSS(RSI,11),LOW,'★低吸 '),COLORFFFFFF;
AA1:=EMA(C,2); { 短指数平滑移动平均线 }
BB1:=EMA(AA1,2); { 平滑 }
A:=MA(BB1,3); { 平均 }
AA2:=EMA((H+C+O)/3,18); { 长指数平滑移动平均线 }
DD3:=A>=AA2 AND C>AA2; { 短>长,且收>长 }
DD4:=A<AA2 ; { 短<长 }
DD5:=A>AA2 ; { 短>长 }
DRAWTEXT(CROSS(84,RSI) , HIGH,'→ 逃顶 '),COLOR00FF00 ;
RSV1:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;
KK:=SMA(RSV1,3,1);
DD:=SMA(KK,3,1);
JJ:=3*KK-2*DD;
M:=BARSLAST(CROSS(DD,JJ));
警示线:REF(H,M),POINTDOT,COLORYELLOW;{进场; 止赢; 止损; 黄}
STICKLINE(警示线,警示线,警示线,3.8,1),COLORYELLOW;
A1:=BACKSET(REF(H,2)=HHV(H,5),3);
A2:=BACKSET(REF(L,2)=LLV(L,5),3);
A3:=CROSS(A1,0.9);
A4:=CROSS(A2,0.9);
上沿:REF(H,BARSLAST(A3)),CIRCLEDOT,COLORFF8918;
{STICKLINE(C,REF(H,BARSLAST(A3)),REF(H,BARSLAST(A3)),5,1),COLORFF8918;}
下沿:REF(L,BARSLAST(A4)),CIRCLEDOT,COLORRED;
{STICKLINE(C,REF(L,BARSLAST(A4)),REF(L,BARSLAST(A4)),5,1);}
AA05:=MA(C,5),COLOR0099CC;
五日乖离率:=(C-AA05)/AA05*100;
BB05:=ATAN((AA05/REF(AA05,1)-1)*100)*180/3.1416;
速度5:=SMA(EMA((AA05-REF(AA05,1))/REF(AA05,1),3)*100,3,1);
加速度5:=EMA((速度5-REF(速度5,1)),3);
AA10:=MA(C,10);
AA20:=MA(C,20);BB10:=ATAN((AA10/REF(AA10,1)-1)*100)*180/3.1416;
AA30:=MA(C,30);
三拾日乖离率:=(C-AA30)/AA30*100;
VAR11:=(AA20-AA30)>REF((AA20-AA30),1)
AND AA20>REF(AA20,1) AND AA30>REF(AA30,1);
VAR22:=(AA30-AA20)<REF((AA30-AA20),1) AND AA20<REF(AA20,1) AND
AA30<REF(AA30,1);
BB30:=ATAN((AA30/REF(AA30,1)-1)*100)*180/3.1416;
强势狙击:=FILTER(BB30>30 AND BB10>45 AND
CROSS(BB05,60),10);
加仓:=FILTER(COUNT(CROSS(BB05,30),5)>=1 AND
AA05>REF(AA05,1) AND 三拾日乖离率>REF(三拾日乖离率,1) AND
AA10>REF(AA10,1)
AND 加速度5>REF(加速度5,1) AND 速度5>REF(速度5,1) ,10) ;
清仓:=FILTER(COUNT(CROSS(30,BB05),5)>=1 AND (C>AA30 OR O>AA30) AND
AA05<REF(AA05,1) AND 三拾日乖离率<REF(三拾日乖离率,1) AND
AA10<REF(AA10,1),10);
DRAWICON(加仓,L,25),COLORRED;
N1:=5;N2:=10;
{STICKLINE(C>0,0,10,15,0),COLOR781816;}
LC1:=REF(CLOSE,1);
RSI5:=SMA(MAX(CLOSE-LC1,0),N1,1)/SMA(ABS(CLOSE-LC1),N1,1)*10,COLORFF00FF,LINETHICK1;
RSI10:=SMA(MAX(CLOSE-LC1,0),N2,1)/SMA(ABS(CLOSE-LC1),N2,1)*10,COLOR00FFFF;
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) AND COUNT(VAR2<0,2) AND CROSS(VAR2,MA(VAR2,2))) AND
REF(DOWN,1)<REF(DOWN,2) AND UP>REF(DOWN,1);
HR:=HHV(HIGH,55);
HRY:=LLV(LOW,55);
HRY11:=HR*HRY;
HRY33:=SQRT(HRY11);
TJ2:=REF(DOWN,1)<REF(DOWN,2) AND UP>REF(DOWN,1) AND C<HRY33;
DRAWICON(TJ2,L*0.999,17),COLOR00FFFF;
X1:=(C+L+H)/3;
X2:=EMA(X1,6);
X3:=EMA(X2,5);
{DRAWICON(CROSS(X2,X3),L*0.97,7);
DRAWICON(CROSS(X3,X2),H*1.02,8); }
STICKLINE(X2>=X3,LOW,HIGH,0,1),COLORRED;
STICKLINE(X2>=X3,CLOSE,OPEN,3.2,2),COLORRED;
STICKLINE(X2<X3,LOW,HIGH,0,1),COLORBLUE;
STICKLINE(X2<X3,CLOSE,OPEN,3.2,2),COLORBLUE;
STICKLINE(CROSS(X3,X2),OPEN,CLOSE,3.2,0),COLORBLUE;
STICKLINE(CROSS(X2,X3),OPEN,CLOSE,3.2,0),COLORRED;
STICKLINE((CLOSE>OPEN) AND (X2<X3),CLOSE,OPEN,3.2,2)COLORBLUE;
STICKLINE((CLOSE>OPEN) AND (X2>=X3),CLOSE,OPEN,3.2,2)COLORRED;
STICKLINE((CLOSE<OPEN) AND (X2<X3),CLOSE,OPEN,3.2,0)COLORBLUE;
STICKLINE((CLOSE<OPEN) AND (X2>=X3),CLOSE,OPEN,3.2,0)COLORRED;
特别提示:
选股预警指标编写 ,不同主流行情软件间指标转换。 请联系微信:396950280