飞狐混沌鳄鱼线副图指标
-
相关简介:飞狐混沌鳄鱼线副图指标 源码 Y:=(H+L)/2; BLUE:=SMA(Y,13,1),SHIFT8,COLORBLUE; RED:=SMA(Y,8,1),SHIFT5,COLORRED; GREEN:=SMA(Y,5,1),SHIFT3,COLORGREEN; B2:=REF(BLUE,8); R2:=REF(RED,5); G2:=REF(GREEN,3); KU1:=IF(H=HHV(H,3),1,0); KD1:=IF(L=LLV(L,3),1,0); UL:=IF(REF(KU1,2
-
文章来源:股海网作者:股海网发布时间:2016-04-10浏览次数:
飞狐混沌鳄鱼线副图指标
源码
Y:=(H+L)/2;
BLUE:=SMA(Y,13,1),SHIFT8,COLORBLUE;
RED:=SMA(Y,8,1),SHIFT5,COLORRED;
GREEN:=SMA(Y,5,1),SHIFT3,COLORGREEN;
B2:=REF(BLUE,8);
R2:=REF(RED,5);
G2:=REF(GREEN,3);
KU1:=IF(H=HHV(H,3),1,0);
KD1:=IF(L=LLV(L,3),1,0);
UL:=IF(REF(KU1,2)=1 AND REF(KU1,1)=0 AND KU1=0,REF(H,2),REF(H,2+BARSLAST(REF(KU1,2)=1 AND REF(KU1,1)=0 AND KU1=0)));
DL:=IF(REF(KD1,2)=1 AND REF(KD1,1)=0 AND KD1=0,REF(L,2),REF(L,2+BARSLAST(REF(KD1,2)=1 AND REF(KD1,1)=0 AND KD1=0)));
KU:=IF(C>B2 AND C>R2 AND C>G2,1,0);
KD:=IF(C<B2 AND C<R2 AND C<G2,-1,0);
KK:=IF(BARSLAST(KU=1 AND REF(KU,1)=0)<BARSLAST(KD=-1 AND REF(KD,1)=0),1,-1);
AO:=MA(Y ,5 )-MA(Y ,34 );
AC:=AO-MA( AO,5);
ac1:=ref(AC,1);
ao1:=ref(ao,1);
AO转:(170*MA(Y,5)-170*MA(Y,34)+165*MA(Y,33)-136*MA(Y,4))/29,linethick0;
AO零:(165*ma(Y,33)-136*ma(Y,4))/29,linethick0;
AC转:(5*34*5*AO-5*34*5*MA(AO,5)+5*34*4*MA(AO,4)+5*4*33*MA(Y,33)-4*34*4*MA(Y,4))/116,linethick0;
AC零:(5*34*MA(AO,4)-34*4*MA(Y,4)+5*33*MA(Y,33))/29,linethick0;
KAC:=IF(AC>ac1 AND Ao>ao1,1,0);
KAO:=IF(AC<ac1 AND Ao<ao1,-1,0);
蓝:SMA(Y,13,1),SHIFT8,COLORBLUE;
红:SMA(Y,8,1),SHIFT5,COLORRED;
绿:SMA(Y,5,1),SHIFT3,COLORGREEN;
上碎型:IF(H>=R2,UL,REF(UL,BARSLAST(H>R2))),COLORMAGENTA,linethick0;
下碎型:IF(L<=R2,DL,REF(DL,BARSLAST(L<=R2))),COLORYELLOW,linethick0;
STICKLINE(BARSLAST(ABS(上碎型-REF(上碎型,1)))<BARSLAST(c>上碎型 AND REF(c,1)<REF(上碎型,1)),上碎型,上碎型,3,1),COLORMAGENTA;
STICKLINE(BARSLAST(ABS(下碎型-REF(下碎型,1)))<BARSLAST(c<下碎型 AND REF(c,1)>REF(下碎型,1)),下碎型,下碎型,3,1),COLORYELLOW;
OL:=(170*MA(Y,5)-170*MA(Y,34)+165*MA(Y,33)-136*MA(Y,4))/29,shift1,color000033;
CL:=(165*ma(y,33)-136*ma(y,4)+170*(4*MA(AO,4)+5*(REF(AO,4)-MA(REF(AO,4),5)))/4)/29,shift1,color000033;
H1:=REF(H,4);
H2:=REF(H,3);
H3:=REF(H,2);
H4:=REF(H,1);
H5:=H;
L1:=REF(L,4);
L2:=REF(L,3);
L3:=REF(L,2);
L4:=REF(L,1);
L5:=L;
∥:=(H3>H2) And (H3>H1) And (H3>H4) And (H3>H5);
∥Fractal:=IF(∥,1,0);
∥Var1:=BackSet(∥Fractal,3);
∥Var2:=Filter(∥Var1,2);
∥Var3:=BackSet(∥Fractal,5);
∣:=(L3<L2) And (L3<L1) And (L3<L4) And (L3<L5);
∣Fractal:=IF(∣,1,0);
∣Var1:=BackSet(∣Fractal,3);
∣Var2:=Filter(∣Var1,2);
∣Var3:=BackSet(∣Fractal,5);
DrawIcon(∥Var2,H*1.001,'S14');
DrawIcon(∣Var2,L,'S14');
DRAWICON(c>上碎型 AND REF(c,1)<REF(上碎型,1),H*1.015,4);
DRAWICON(c<下碎型 AND REF(c,1)>REF(下碎型,1),L*0.99,5);
DRAWICON(KU=1 AND REF(KU,1)=0 and c<0,L,4);
DRAWICON(KD=-1 AND REF(KD,1)=0 and c<0,H*1.01,5);
DRAWICON(KU=0 AND REF(KU,1)=1 and c<0,H*1.01,7);
DRAWICON(KD=0 AND REF(KD,1)=-1 and c<0,L,6);
STICKLINE(KAC=1 AND C>=O,O,C,8,1),COLORRED;
STICKLINE(KAO=-1 AND C>=O,O,C,8,1),COLORGREEN;
STICKLINE(KAO=0 AND KAC=0 AND C>=O,O,C,8,1),COLORGRAY;
STICKLINE(C>=O,H,C,0.4,1),COLORRED;
STICKLINE(C>=O,O,L,0.4,1),COLORRED;
STICKLINE(KAC=1 AND C<O,O,C,8,0),COLORRED;
STICKLINE(KAO=-1 AND C<O,O,C,8,0),COLORGREEN;
STICKLINE(KAO=0 AND KAC=0 AND C<O,O,C,8,0),COLORGRAY;
STICKLINE(O>C,H,O,0.4,1),COLORCYAN;
STICKLINE(O>C,C,L,0.4,1),COLORCYAN;
DU0:=CROSS(AO,0);
UD0:=CROSS(0,AO);
TDU0:=BARSLAST(DU0);
TUD0:=BARSLAST(UD0);
DU3:=REF(DU0,1);
UD3:=REF(UD0,1);
TDU3:=BARSLAST(DU3);
TUD3:=BARSLAST(UD3);
UDGLINE:IF(TDU3<TUD3,REF(HHV(H,2),TDU3),REF(LLV(L,2),TUD3)),COLORYELLOW;
JDU0:=REF(C,1)<=REF(UDGLINE,1) AND C>UDGLINE AND TDU0<TUD0;
JUD0:=REF(C,1)>=REF(UDGLINE,1) AND C<UDGLINE AND TUD0<TDU0;
JDU1:=JDU0 AND COUNT(JDU0,TDU0)=1;
JUD1:=JUD0 AND COUNT(JUD0,TUD0)=1;
JDU2:=JDU1 AND REF(BARSLAST(JUD1),1)<REF(BARSLAST(JDU1),1);
JUD2:=JUD1 AND REF(BARSLAST(JUD1),1)>REF(BARSLAST(JDU1),1);
JDU3:=JDU1 AND REF(BARSLAST(JUD1),1)>REF(BARSLAST(JDU1),1);
JUD3:=JUD1 AND REF(BARSLAST(JUD1),1)<REF(BARSLAST(JDU1),1);
DRAWTEXT(JDU2,L*0.98,'\n空\n转\n多'),align4;
DRAWTEXT(JUD2,H*1.03,'\n多\n转\n空'),align5;
DRAWTEXT(JDU3,L*0.98,'\n多\n续\n多'),align4;
DRAWTEXT(JUD3,H*1.03,'\n空\n续\n空'),align5;
BSLINE:=IF(BARSLAST(JDU2)<BARSLAST(JUD2),IF(REF(CROSS(0,AC),1) OR REF(CROSS(0,AO),1),LLV(L,2),REF(LLV(L,2),BARSLAST(REF(CROSS(0,AC),1) OR REF(CROSS(0,AO),1)))),IF(REF(CROSS(AC,0) OR REF(CROSS(AO,0),1),1),HHV(H,2),REF(HHV(H,2),BARSLAST(REF(CROSS(AC,0),1) OR REF(CROSS(AO,0),1))))),COLORyellow;
DRAWICON(JDU1 OR BARSLAST(JDU1)<BARSLAST(JUD1),C,10),ALIGN4;
DRAWICON(JUD1 OR BARSLAST(JDU1)>BARSLAST(JUD1),C,11),ALIGN5;