擒牛伏妖,牛启动,龙头擒妖公式组(通达信公式 副图 主图 测试图)
{擒牛伏妖主图源码:}所属地区:DRAWTEXT_FIX(1,0.00,0.05,0,'地区:'),COLORFFFF00;DRAWTEXT_FIX(1,0.05,0.05,0,DYBLOCK),COLORFFFF00;所属行业:DRAWTEXT_FIX(1,0,0.10,0,'行业:'),COLORFFFF00;DRAWTEXT_FIX(1,0.05,0.10,0,HYBLOCK),COLORFFFF00;所属概念:DRAWTEXT_FIX(1,0,0.15,0,'概念:'),COLORFFFF00;DRAWTEXT_FIX(1,0.05,0.15,0,GNBLOCK),COLORFFFF00;所属风格:DRAWTEXT_FIX(1,0,0.20,0,'风格:'),COLORFFFF00;DRAWTEXT_FIX(1,0.05,0.20,0,FGBLOCK),COLORFFFF00;上市日期:=CONST(DAYTODATE((DATETODAY(DATE)-FINANCE(42))))+19000000,NODRAW;DRAWTEXT_FIX(1,0,0.25,0,'上市日期:'),COLORFFFF00;DRAWNUMBER_FIX(1,0.05,0.25,0,上市日期),COLORFFFF00;MA5:=MA(C,5);MA20:=MA(C,20);A51:= REF(MA5,1)*0.98;A52:= REF(MA5,2)*0.98;B52:= BARSLAST(REF(C,2)>=REF(MA5,2) AND REF(C,1)<REF(MA5,1))+2;B51:= BARSLAST(REF(C,2)>=REF(MA5,2) AND REF(C,1)<REF(MA5,1))+1;DZ:=IF((REF(C,2)>=REF(MA5,2)) AND (REF(C,1)<REF(MA5,1)),IF(REF(MA5,2)<REF(MA5,1),A51,A52),IF(BARSSINCE(REF(C,2)>=REF(MA5,2) AND REF(C,1)<REF(MA5,1))>0,IF(REF(MA5, B52)< REF(MA5, B51),REF(MA5,B51)*0.98, REF(MA5,B52)*0.98), REF(MA5,1)));A201:= REF(MA20,1)*0.98;A202:= REF(MA20,2)*0.98;B202:= BARSLAST(REF(C,2)>=REF(MA20,2) AND REF(C,1)<REF(MA20,1))+2;B201:= BARSLAST(REF(C,2)>=REF(MA20,2) AND REF(C,1)<REF(MA20,1))+1;ZZ:=IF((REF(C,2)>=REF(MA20,2)) AND (REF(C,1)<REF(MA20,1)),IF(REF(MA20,2)<REF(MA20,1),A201,A202),IF(BARSSINCE(REF(C,2)>=REF(MA20,2) AND REF(C,1)<REF(MA20,1))>0,IF(REF(MA20, B202)< REF(MA20, B201),REF(MA20,B201)*0.98, REF(MA20,B202)*0.98), REF(MA20,1)));短止:DZ,COLORWHITE,LINETHICK2;紫线:ZZ,COLORMAGENTA;绿线:LLV(REF(LOW,1),2)+(HHV(REF(HIGH,1),2)-LLV(REF(LOW,1),2))/2,COLORGREEN;黄线:MA(CLOSE,25)+MA(CLOSE,25)*6/100,COLORYELLOW,LINETHICK2;白轨:MA(CLOSE,25)+MA(CLOSE,25)*20/100,COLORWHITE;影子线:MA(CLOSE,25)+MA(CLOSE,25)*13/100,COLORGRAY;STICKLINE(C/REF(C,1)>1.095,C,O,2,0),COLORYELLOW;AZZ:=LLV(REF(LOW,1),2)+(HHV(REF(HIGH,1),2)-LLV(REF(LOW,1),2))/2,COLORGREEN;DRAWICON(REF(C,1)<REF(DZ,1) AND C>=DZ AND C>AZZ ,LOW*0.99,1);DRAWICON(REF(C,1)<REF(AZZ,1) AND C>=AZZ,LOW*0.99,1);AXX:=((((MA(C,10) > MA(C,25)) && CROSS(C,MA(C,5))) && (V > MA(V,10))) && (MA(C,10) > REF(MA(C,10),1)));ASS:=C>=黄线 AND AXX ;DRAWTEXT(ASS,L*0.99,'☆'), COLORGREEN;DRAWTEXT_FIX(ISLASTBAR,0,0.00,0,'说明: ☆为稳买'),COLORLIGREEN;涨停:=IF((C-REF(C,1))*100/REF(C,1)>=(10-0.01*100/REF(O,1)),1,0);STICKLINE(涨停,O,C,1,0),COLORYELLOW;XA:=(ATAN((MA(C,3)/REF(MA(C,3),1)-1)*100)*180/3.14115926)>60;XB:=C/REF(C,2)>1.08 AND C=HHV(C,40);妖股:XA AND XB AND BARSCOUNT(C)>19,NODRAW,COLORYELLOW;DRAWICON(妖股,L,13);DRAWTEXT(妖股,L*0.92,'妖股'),COLORYELLOW;XC:=C=ZTPRICE(REF(C,1),0.1);STICKLINE(XC,C,O,0.5,0)COLORYELLOW;STICKLINE(XC,H,L,0.5,0),COLORYELLOW;倍量:=V>REF(MA(V,5),1)*1.8 AND C>REF(C,1) AND BARSCOUNT(C)>15;DRAWTEXT(倍量,L*0.97,'倍'),COLORMAGENTA,LINETHICK2;DRAWTEXT(CROSS((REF(HIGH,1)+REF(LOW,1))/2,MA(CLOSE,20)+2*STD(CLOSE,20)),HIGH*1.02,'●警'),COLORGREEN;{买入}A3:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;A4:=SMA(A3,3,1);A5:=SMA(A4,3,1);A6:=3*A4-2*A5;A7:=C-REF(C,1);A8:=100*EMA(EMA(A7,6),6)/EMA(EMA(ABS(A7),6),6);买:=LLV(A8,2)=LLV(A8,7) AND COUNT(A8<0,2) AND CROSS(A8,MA(A8,2));DRAWTEXT(FILTER(买=1,5),LOW-0.05,'买进'),COLORYELLOW;STICKLINE(买,OPEN,CLOSE,2,0),COLORYELLOW;STICKLINE(C/REF(C,1)>1.095,C,O,2,0),COLORMAGENTA;N:=12;DG:=1.2;YLX:=0;ZCX:=0;A1:=REF(C,N)=HHV(C,2*N+1); B1:=FILTER(A1,N); C1:=BACKSET(B1,N+1); HD:=FILTER(C1,N);A2:=REF(C,N)=LLV(C,2*N+1); B2:=FILTER(A2,N); C2:=BACKSET(B2,N+1); LD:=FILTER(C2,N);UU:=BACKSET(BARSTATUS=2,BARSLAST(HD)+1);VV:=UU>REF(UU,1);前高:REF(C,BARSLAST(VV)),COLORRED,LINETHICK2;顶高:=REF(C,BARSLAST(VV))*DG,COLORGRAY,LINETHICK2;PTZQ:=BARSLAST(VV);PTZF:=(HHV(H,PTZQ)-LLV(L,PTZQ))/LLV(L,PTZQ)*100;DRAWTEXT_FIX(1,0.5,0.04,0,STRCAT(STRCAT('平台周期 ',CON2STR(PTZQ,0)),' 天')),COLORRED;DRAWTEXT_FIX(1,0.5,0.08,0,STRCAT(STRCAT('平台振幅 ',CON2STR(PTZF,0)),' %')),COLORYELLOW;
{龙头擒妖 副图}DRAWGBK(C>O,RGB(10,0,0),RGB(0,0,0),1,2,1);XA_1:=DYNAINFO(4)>0 AND HHV(HIGH,10)/LLV(LOW,10)<1.25 AND REF(CLOSE,1)<LLV(LOW,15)+(HHV(HIGH,15)-LLV(LOW,15))*0.85 AND CLOSE>OPEN AND CLOSE>=HHV(HIGH,10);XA_2:=IF(DATETODAY(DATE)<15000000,1,DRAWNULL);XA_3:=EMA(CLOSE,5);XA_4:=EMA(CLOSE,10);XA_5:=EMA(CLOSE,14);XA_6:=EMA(CLOSE,18);XA_7:=EMA(CLOSE,40);XA_8:=EMA(CLOSE,60);XA_9:=IF(DATE<30000*500,1,DRAWNULL);XA_10:=MAX(XA_7,XA_8);XA_11:=CLOSE>XA_10 AND XA_1 AND (CLOSE>REF(HHV(HIGH,3),1)*XA_2 AND (CLOSE-REF(CLOSE,1))/REF(CLOSE,1)>0.07);XA_12:=VOL;XA_13:=MA(XA_12,5);XA_14:=XA_13+XA_13>XA_12;XA_15:=DYNAINFO(4)>0 AND HHV(HIGH,10)/LLV(LOW,10)<1.25 AND REF(CLOSE,1)<(LLV(LOW,15)+(HHV(HIGH,15)-LLV(LOW,15))*0.85)*XA_2 AND CLOSE>OPEN AND CLOSE>=HHV(HIGH,10)*XA_9;XA_16:=(CLOSE>REF(HHV(HIGH,3),1)*XA_2 AND (CLOSE-REF(CLOSE,1))/REF(CLOSE,1)>0.07)*XA_2 AND XA_15 AND XA_14;XA_17:=DYNAINFO(4)>0 AND HHV(HIGH,10)/LLV(LOW,10)<1.25 AND REF(CLOSE,1)*XA_2<LLV(LOW,15)+(HHV(HIGH,15)-LLV(LOW,15))*0.85 AND CLOSE>OPEN AND CLOSE>=HHV(HIGH,10);XA_18:=(CLOSE-REF(CLOSE,1)*XA_2)/REF(CLOSE,1)*100>7;XA_19:=XA_17 AND XA_18;XA_20:=DATETODAY(DATE);XA_21:=XA_20>9344 AND XA_20<15000000;XA_22:=(XA_11 AND XA_19)*XA_21;XA_23:=EMA(CLOSE,5);XA_24:=EMA(CLOSE,10);XA_25:=EMA(CLOSE,14);XA_26:=EMA(CLOSE,18);XA_27:=EMA(CLOSE,40);XA_28:=EMA(CLOSE,60);XA_29:=MAX(MAX(MAX(MAX(MAX(XA_23,XA_4),XA_25),XA_26),XA_27),XA_28)*XA_9;XA_30:=MIN(MIN(MIN(MIN(MIN(XA_23,XA_4),XA_25),XA_26),XA_27),XA_28)*XA_9;XA_31:=CLOSE>XA_29 AND LOW<XA_30 AND (CLOSE>REF(HHV(HIGH,3),1) AND (CLOSE-REF(CLOSE,1)*XA_2)/REF(CLOSE,1)>0.09);XA_32:=FILTER(XA_31>0,0)=1;XA_33:=DATETODAY(DATE);XA_34:=XA_33>9350 AND XA_33<15000000;XA_35:=XA_32*XA_34;XA_36:=MA(REF(HHV(CLOSE,26),1),2);XA_37:=MA(CLOSE,26);XA_38:=POW(CLOSE-XA_37,2);XA_39:=MA(XA_38,13);XA_40:=SQRT(XA_39);XA_41:=XA_37+2*XA_40;XA_42:=REF(XA_41,1);XA_43:=CROSS(CLOSE,XA_36) AND HIGH>REF(XA_41,1) OR (CLOSE>XA_36 AND CROSS(CLOSE,REF(XA_41,1))) AND CLOSE/OPEN>0.998;XA_44:=MACD.MACD;XA_45:=KD.K;XA_46:=KD.D;XA_47:=RSI.RSI1;XA_48:=RSI.RSI3;XA_49:=CLOSE-REF(CLOSE,1);XA_50:=IF(XA_49>=0,XA_49,0)*XA_9;XA_51:=IF(XA_49<0,-XA_49,0)*XA_9;XA_52:=MEMA(XA_50,10);XA_53:=MEMA(XA_51,10);XA_54:=MEMA(XA_50,6);XA_55:=MEMA(XA_51,6);XA_56:=MA(100*XA_52/(XA_52+XA_53),10)*XA_9;XA_57:=MA(100*XA_54/(XA_54+XA_55),6)*XA_9;XA_58:=MA(CLOSE,5)/MA(CLOSE,10)>0.999 AND MA(CLOSE,10)/MA(CLOSE,20)>0.9847 AND MA(CLOSE,20)>MA(CLOSE,60) AND REF(COUNT(MA(CLOSE,10)/MA(CLOSE,20)<1.017 OR MA(CLOSE,5)/MA(CLOSE,10)<1.017,8)>=1,1) AND MA(CLOSE,20)/MA(CLOSE,60)<1.121;XA_59:=(CLOSE-MA(CLOSE,60))/MA(CLOSE,60)*100;XA_60:=COUNT(XA_59<35,100)>=95;XA_61:=XA_43 AND XA_58>0 AND NOT(DYNAINFO(4)=0) AND XA_60 AND REF(COUNT(MA(CLOSE,20)>MA(CLOSE,30),4)=4 AND COUNT(CLOSE>MA(CLOSE,5),3)>=2,1) AND VOL>REF(VOL,1) AND (REF(COUNT(CLOSE>OPEN,10)>=6 OR COUNT(CLOSE>OPEN,5)>=4,1) OR CLOSE=HIGH) AND (CROSS(XA_57,XA_56) OR CROSS(XA_44,0) OR REF(COUNT(CROSS(XA_44,0),3)=1 AND XA_44<0.15 AND CLOSE/OPEN>0.989 AND CLOSE/REF(CLOSE,1)<1.03,1) OR CROSS(XA_45,XA_46) OR CROSS(XA_47,XA_48)) AND REF(CLOSE/OPEN>0.988 AND (CLOSE>OPEN OR (CLOSE<=OPEN AND HIGH/LOW<1.049)),1) AND HIGH/CLOSE<1.013 AND CLOSE/OPEN>1.05;XA_62:=XA_11+XA_16+XA_19+XA_32+XA_61>=2;XA_63:=MA(CLOSE,5)>MA(CLOSE,10) AND MA(CLOSE,10)>MA(CLOSE,20) AND MA(CLOSE,20)>MA(CLOSE,60) AND MA(CLOSE,60)>MA(CLOSE,120) AND MA(CLOSE,5)>REF(MA(CLOSE,5),1);XA_64:=CLOSE>REF(CLOSE,1)*1.1-0.01;XA_65:=HHV(HIGH,20)=HHV(CLOSE,1) AND VOL>0 AND BARSCOUNT(CLOSE)*XA_2>=20;XA_66:=VOL/REF(VOL,1)*XA_2>1.9;XA_67:=XA_63 AND XA_64 AND XA_65 AND XA_66;XA_68:=MA(CLOSE,5);XA_69:=MA(CLOSE,10);XA_70:=MA(CLOSE,20);XA_71:=MA(CLOSE,30);XA_72:=MA(CLOSE,60);XA_73:=CLOSE>XA_68 AND XA_68>XA_69 AND XA_69>XA_70 AND CLOSE>XA_72;XA_74:=CLOSE/REF(CLOSE,1)>1.05 AND REF(CLOSE,1)/REF(CLOSE,2)<1.05 AND CLOSE/LLV(CLOSE,10)<1.4;XA_75:=VOL/REF(VOL,1)>2 OR VOL=HHV(VOL,15);XA_76:=CAPITAL<10000000;XA_77:=ATAN((MA(CLOSE,5)/REF(MA(CLOSE,5),1)-1)*100)*57.299999>40;XA_78:=ATAN((MA(CLOSE,10)/REF(MA(CLOSE,10),1)-1)*100)*57.299999>30;XA_79:=ATAN((MA(CLOSE,20)/REF(MA(CLOSE,20),1)-1)*100)*57.299999>20;XA_80:=ATAN((MA(CLOSE,30)/REF(MA(CLOSE,30),1)-1)*100)*57.299999>10;XA_81:=XA_77 AND XA_78 AND XA_79 AND XA_80;XA_82:=KDJ.K>REF(KDJ.K,1)*XA_2;XA_83:=KDJ.D>REF(KDJ.D,1)*XA_2 AND KDJ.D<70;XA_84:=KDJ.J>REF(KDJ.J,1)*XA_2;XA_85:=XA_82 AND XA_83 AND XA_84;XA_86:=XA_7 AND XA_74 AND XA_75 AND XA_76 AND XA_81 AND XA_85;XA_87:=FILTER(XA_86,15)*XA_2;XA_88:=XA_67 OR XA_87;龙头:DATE<15000000 AND ((XA_88 AND XA_62)*XA_2 OR XA_35 OR XA_22),NODRAW,COLORRED;STICKLINE(龙头,0,1,2,0),COLORRED;
{牛启动副图:}DRAWGBK(C>O,RGB(10,0,0),RGB(0,0,0),1,2,1);{主图买入}A10:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;A11:=SMA(A10,3,1);A12:=SMA(A11,3,1);A13:=3*A11-2*A12;A14:=C-REF(C,1);A15:=100*EMA(EMA(A14,6),6)/EMA(EMA(ABS(A14),6),6);买入:=LLV(A15,2)=LLV(A15,7) AND COUNT(A15<0,2) AND CROSS(A15,MA(A15,2));MA5:=MA(C,5);MA20:=MA(C,20);角度5:=ATAN((MA(C,5)/REF(MA(C,5),1)-1)*100)*57.3;角度60:=ATAN((MA(C,60)/REF(MA(C,60),1)-1)*100)*57.3;A51:= REF(MA5,1)*0.98;A52:= REF(MA5,2)*0.98;B52:= BARSLAST(REF(C,2)>=REF(MA5,2) AND REF(C,1)<REF(MA5,1))+2;B51:= BARSLAST(REF(C,2)>=REF(MA5,2) AND REF(C,1)<REF(MA5,1))+1;DZ:=IF((REF(C,2)>=REF(MA5,2)) AND (REF(C,1)<REF(MA5,1)),IF(REF(MA5,2)<REF(MA5,1),A51,A52),IF(BARSSINCE(REF(C,2)>=REF(MA5,2) AND REF(C,1)<REF(MA5,1))>0,IF(REF(MA5, B52)< REF(MA5, B51),REF(MA5,B51)*0.98, REF(MA5,B52)*0.98), REF(MA5,1)));A201:= REF(MA20,1)*0.98;A202:= REF(MA20,2)*0.98;B202:= BARSLAST(REF(C,2)>=REF(MA20,2) AND REF(C,1)<REF(MA20,1))+2;B201:= BARSLAST(REF(C,2)>=REF(MA20,2) AND REF(C,1)<REF(MA20,1))+1;ZZ:=IF((REF(C,2)>=REF(MA20,2)) AND (REF(C,1)<REF(MA20,1)),IF(REF(MA20,2)<REF(MA20,1),A201,A202),IF(BARSSINCE(REF(C,2)>=REF(MA20,2) AND REF(C,1)<REF(MA20,1))>0,IF(REF(MA20, B202)< REF(MA20, B201),REF(MA20,B201)*0.98, REF(MA20,B202)*0.98), REF(MA20,1)));短止:=DZ,COLORWHITE,LINETHICK2;紫线:=ZZ,COLORMAGENTA;绿线:=LLV(REF(LOW,1),2)+(HHV(REF(HIGH,1),2)-LLV(REF(LOW,1),2))/2,COLORGREEN;黄线:=MA(CLOSE,25)+MA(CLOSE,25)*6/100,COLORYELLOW,LINETHICK2;白轨:=MA(CLOSE,25)+MA(CLOSE,25)*20/100,COLORWHITE;影子线:=MA(CLOSE,25)+MA(CLOSE,25)*13/100,COLORGRAY;AZZ:=LLV(REF(LOW,1),2)+(HHV(REF(HIGH,1),2)-LLV(REF(LOW,1),2))/2,COLORGREEN;AXX:=((((MA(C,10) > MA(C,25)) && CROSS(C,MA(C,5))) && (V > MA(V,10))) && (MA(C,10) > REF(MA(C,10),1)));ASS:=C>=黄线 AND AXX ;角度黄线:=ATAN((黄线/REF(黄线,1)-1)*100)*180/3.1416;XG6:=ASS AND 买入 AND 角度黄线>0;XG7:=C/REF(C,1)>1.08 AND C>O AND 买入;XG8:=买入 AND 角度黄线>0;XG9:= C>=黄线 AND (CROSS(ZIG(3,10),REF(ZIG(3,10),1))) AND 角度黄线>0;涨停:=(C-REF(C,1))/REF(C,1)*100>9.85 AND C=H;T:=BARSLAST(涨停);XG1:=COUNT(C/REF(C,1)>1.09,15)>1;XG2:= XG6 OR XG7 OR XG8 OR XG9 ;龙回头:XG1 AND XG2,NODRAW,COLORMAGENTA;STICKLINE(龙回头,0,3,2,0),COLORMAGENTA;S:=BARSLAST(龙回头);放心买: S>=1 AND S<=3 AND C/REF(C,1)>1.02 ,NODRAW,COLORGREEN;STICKLINE(放心买,6,9,2,0),COLORGREEN;XG10:=CROSS(C,影子线) AND C/REF(C,1)>1.03 ;XG11:=CROSS(C,黄线) AND C/REF(C,1)>1.05 AND 角度黄线>0 ;XG12:=CROSS(C,白轨);突破牛:XG10 OR XG12 ,NODRAW,COLORRED;STICKLINE(突破牛,3,6,2,0),COLORRED;
内容真的很不错 太棒了吧,真的很好 有道理。。。
页:
[1]