通达信拐点擒龙主图指标公式

N:=3;
A线:EMA(EMA(EMA(EMA(CLOSE,2),2),2),2),LINETHICK1,COLOR0000FF;
B线:EMA(REF(A线,1),2),LINETHICK1,COLOR00FFFF;
趋势:EMA(EMA(EMA(EMA(EMA(CLOSE,55),2),2),2),2),LINETHICK1,COLORFF00FF;
C2:=REF(C,1);
VAR1:=ZIG(3,10)<REF(ZIG(3,10),1) AND REF(ZIG(3,10),1)>REF(ZIG(3,10),2);{ZIG 有未来}
VAR2:=ZIG(3,10)>REF(ZIG(3,10),1) AND REF(ZIG(3,10),1)<REF(ZIG(3,10),2);
STICKLINE(VAR1,C,O,2,0),COLORYELLOW,LINETHICK1;{高位黄色}
STICKLINE(VAR1,C,O,2,0),COLORYELLOW,LINETHICK1;{高位黄色}
STICKLINE(VAR1,H,L,1,0),COLORYELLOW,LINETHICK1;{高位黄色}
STICKLINE(VAR2,C,O,2,0),COLORFF00FF,LINETHICK1;{底位红色}
STICKLINE(VAR2,C,O,2,0),COLORFF00FF,LINETHICK1;{底位红色}
STICKLINE(VAR2,H,L,1,0),COLORFF00FF,LINETHICK1;{底位红色};
AA:DRAWTEXT(CROSS(ZIG(3,8),REF(ZIG(3,8),1)),LOW*0.978,'★拐点底') ,LINETHICK2,COLORYELLOW;
DRAWTEXT(CROSS(REF(ZIG(3,10),1),ZIG(3,10)),HIGH*1.02,'波段顶 '),LINETHICK2,COLOR00FF00;
MA1:=MA(VAR1,3);
VAR3:=LLV(HIGH,240);
VAR4:=100*(CLOSE-VAR3)/VAR3;
VAR5:=(CLOSE-LLV(LOW,528))/(HHV(HIGH,528)-LLV(LOW,528))*100;
VAR6:=(CLOSE-LLV(CLOSE,530))/(HHV(CLOSE,530)-LLV(CLOSE,530))*100;
VAR7:=0;
VAR8:=SMA(MAX(CLOSE-REF(CLOSE,1),0),34,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),7,1)*100;
VAR9:=SMA(MAX(CLOSE-REF(CLOSE,1),0),13,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),13,1)*100;
VAR10:=IF(TROUGHBARS(3,16,1)=0 AND HIGH>LOW+0.04,4,0);
VAR11:=ZIG(3,6)>REF(ZIG(3,6),1) AND REF(ZIG(3,6),1)<=REF(ZIG(3,6),2) AND REF(ZIG(3,6),2)<=REF(ZIG(3,6),3);
VAR12:=ZIG(3,6)<REF(ZIG(3,6),1) AND REF(ZIG(3,6),1)>=REF(ZIG(3,6),2) AND REF(ZIG(3,6),2)>=REF(ZIG(3,6),3);
VAR13:=ZIG(3,22)>REF(ZIG(3,22),1) AND REF(ZIG(3,22),1)<=REF(ZIG(3,22),2) AND REF(ZIG(3,22),2)<=REF(ZIG(3,22),3);
VAR14:=ZIG(3,22)<REF(ZIG(3,22),1) AND REF(ZIG(3,22),1)>=REF(ZIG(3,22),2) AND REF(ZIG(3,22),2)>=REF(ZIG(3,22),3);
VAR15:=ZIG(3,51)>REF(ZIG(3,51),1) AND REF(ZIG(3,51),1)<=REF(ZIG(3,51),2) AND REF(ZIG(3,51),2)<=REF(ZIG(3,51),3);
VAR16:=ZIG(3,51)<REF(ZIG(3,51),1) AND REF(ZIG(3,51),1)>=REF(ZIG(3,51),2) AND REF(ZIG(3,51),2)>=REF(ZIG(3,51),3);
VAR17:=ZIG(3,72)>REF(ZIG(3,72),1) AND REF(ZIG(3,72),1)<=REF(ZIG(3,72),2) AND REF(ZIG(3,72),2)<=REF(ZIG(3,72),3);
VAR18:=ZIG(3,72)<REF(ZIG(3,72),1) AND REF(ZIG(3,72),1)>=REF(ZIG(3,72),2) AND REF(ZIG(3,72),2)>=REF(ZIG(3,72),3);
VAR19:=EMA(CLOSE,2)-EMA(CLOSE,150);
买1:=VAR10;
买2:=(VAR11+VAR13+VAR15+VAR17);
卖1:=(VAR12+VAR14+VAR16+VAR18);
DRAWICON((ZIG(3,5)>REF(ZIG(3,5),1)) AND (REF(ZIG(3,5),1)<=REF(ZIG(3,5),2)) AND (REF(ZIG(3,5),2)<=REF(ZIG(3,5),3)),LOW*0.98,1) ;
DRAWICON((ZIG(3,5)<REF(ZIG(3,5),1)) AND (REF(ZIG(3,5),1)>=REF(ZIG(3,5),2)) AND (REF(ZIG(3,5),2)>=REF(ZIG(3,5),3)),HIGH*1.01,2);
ZB:=EMA(EMA(VAR3,5),5)*3, ;
VARA:=IF(VAR9 AND CROSS(MA(CLOSE,3),MA(CLOSE,5)),20,0);
K:= 5 *2, , COLORFF00FF;
D:= 5 , , COLORWHITE;
J:=K*3-D*2, ,COLORYELLOW;
VARB:=BETWEEN(CLOSE,MA(CLOSE,3),MA(CLOSE,5)) AND J>10;
HS:=VOL/CAPITAL*100, , COLORGREEN;
VARE:=MA(100*(CLOSE-LLV(CLOSE,34))/(HHV(HIGH,34)-LLV(LOW,34)),5)-20;
VARF:=100-3*SMA((CLOSE-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1)+2*SMA(SMA((CLOSE-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1),15,1);
VAR1A:=IF(VARE>0,VARE,0);
VAR1B:=IF(VAR14>=200 AND VAR13>=150,15,IF(VAR14<=-200 AND VAR13<=-150,-15,VAR16))+60;
VAR1C:=VAR1A>48 AND VAR1B>60 AND VAR19<100;
STICKLINE((C-REF(C,1))/REF(C,1)>=0.0985,O,C,2,0),COLORYELLOW;
STICKLINE((C-REF(C,1))/REF(C,1)>=-0.0985 AND (C-REF(C,1))/REF(C,1)<0,O,C,2,0),COLORCYAN;
STICKLINE(C>REF(C,1) AND C<O ,O,C,2,0),COLORCYAN;
STICKLINE((C-REF(C,1))/REF(C,1)<=-0.0985,O,C,2,0),COLORBLUE;

(0)

相关推荐