AHC1:=CLOSE*vol;
AHC22:=EMA((expma(AHC1,23)/EXPMA(VOL,23)+EXPMA(AHC1,54)/EXPMA(VOL,54)+EXPMA(AHC1,108)/EXPMA(VOL,108)+EXPMA(AHC1,316)/EXPMA(VOL,316))/4,34);
通道:=1.0668*AHC22;
起爆:=crOSS(C,通道) AND REF(C,1)*1.05-C<0.008 AND C>O*0.5;
RRF:=起爆;
STICKLINE(IF(RRF,-120,0),+12,0,2,0),COLORMAGENTA;
STICKLINE(IF(RRF,-120,0),+8,0,2,0),COLORYELLOW;
STICKLINE(RRF,0,4,2,0),COLORGREEN;
DRAWTEXT(RRF,10,'黑马一号'),COLORYELLOW;
A1:=Abs(((3.48*CLOSE+HIGH+LOW)/4-EMA(CLOSE,23))/EMA(CLOSE,23));
A2:=DMA(((2.15*CLOSE+LOW+HIGH)/4),A1);
金线王:=EMA(A2,200)*1.118;
金线王2:=EMA(A2,200)*1.118;
条件:=(C-REF(C,1))/REF(C,1)*100>8;
金k线:=CROSS(C,金线王) AND 条件;
STICKLINE(金K线,8,0,2,0),COLORRED;
DRAWTEXT(金K线,6,'黑马启动'),COLORYELLOW;
AA05:=MA(C,5);
AA30:=MA(C,30);
MA05:=MA(C,5);
MA10:=MA(C,13);
MA30:=MA(C,34);
速度5:=SMA(EMA((MA05-REF(MA05,1))/REF(MA05,1),3)*100,3,1);
加速度5:=EMA((速度5-REF(速度5,1)),3);
五日乖离率:=(C-AA05)/AA05*100;
三拾日乖离率:=(C-MA30)/MA30*100;
MR:=COUNT(CROSS(五日乖离率,0),3)>=1 AND 三拾日乖离率>REF(三拾日乖离率,1) AND AA05>REF(AA05,1) AND (C/REF(C,1)-1)*100>5 AND REF(C,1)<AA30;
买入:=FILTER(MR,10);
STICKLINE(买入,4,0,2,0),COLORMAGENTA;
DRAWTEXT(买入,2,'黑马必抓'),COLORYELLOW;