K2:=1;
KN:=10;
MA1:MA(C,5),COLORWHITE;
MA2:MA(C,13),COLORRED;
{4、黄色块及坑后上涨;K线低位黄金坑。有未来。
该组源码的作用是:在大盘股指的时间周期末端,波段拉升前的挖坑洗盘重要标志。
该标志,仅仅作为分辨右侧交易前,研判大牛股启动的左侧黄色K线坑的建仓洗盘。并非左侧买进信号!}
NQ:=20;
M1P:=30;
P1P:=80;
P2P:=100;
VAR1P:=(C+H+O+L)/4;
买入P:=XMA(VAR1P,M1P)*(1-P2P/1000),COLORYELLOW,LINETHICK2;
STICKLINE(买入P>HIGH,OPEN,CLOSE,2,0),COLORYELLOW;{与黑马通道低位黄块异曲同工}
STICKLINE(买入P>HIGH,HIGH,LOW,0,0),COLORYELLOW;{与黑马通道低位黄块异曲同工};
STICKLINE(CCI<=100 AND L<=买入P,(L + H + O) / 3.18,O,2,0),COLORYELLOW;
反弹P:=MA(EMA(EMA(HIGH,5),5),5)*0.95,LINETHICK1;
XG1P:=CROSS(买入P,反弹P);
STICKLINE(XG1P,L*1.1,L*1.05,000.1,0),COLORWHITE;
DRAWTEXT(XG1P,L*1.1,'★坑后上涨'),COLORCYAN;
{13、飓风眼启爆,K线下方蓝色柱,股价启动信号,无函数}
AHC1:=CLOSE*VOL;
AHC2:=EMA((EXPMA(AHC1,2)/EXPMA(VOL,2)+EXPMA(AHC1,5)/EXPMA(VOL,5)+EXPMA
(AHC1,10)/EXPMA(VOL,10)+EXPMA(AHC1,20)/EXPMA(VOL,20))/4,10),COLORYELLOW;
风向R:=1.06*AHC2,LINETHICK2,COLORWHITE;
吹:=1.13*AHC2,LINETHICK2,COLORWHITE;
ZT:=REF(C,1)*1.1-C<0.01 AND H=C;
飓风:=CROSS(C,风向R) AND ZT;
STICKLINE(飓风,L*0.99,L*0.96,2,0),COLORBLUE;
{7、黑夜之眼;波段低点。研判拉升前是否有资金活动吸筹。左侧交易信号。无未来}
MMM:=1;
SVOL:=INTPART(SUM(V,0)/CAPITAL);
TJ0:=SVOL>REF(SVOL,1) OR BARSSINCE(CLOSE)=0;
SF1:=BARSLAST(TJ0)+1;
TJJ2:=SF1<REF(SF1,1);
S2:=IF(TJJ2,REF(SF1,1)+1,SF1);
S3:=SUM(TJJ2,0);
ZK1:="KD.K#WEEK"(9,3,3);
ZD2:="KD.D#WEEK"(9,3,3);
ZF1:="MACD.DIF#WEEK"(5,34,5);
ZA2:="MACD.DEA#WEEK"(5,34,5);
换手:=V/CAPITAL*100,LINETHICK0;
JCD:=CROSS(ZK1,ZD2) AND REF(ZD2,1)<60;
波段低点:=EXIST(JCD,MMM),COLORYELLOW,NODRAW;
STICKLINE(波段低点,L*0.98,L*0.94,1,0),COLORBROWN;
DRAWTEXT(波段低点,L*0.94,'--黑夜之眼'),COLORGREEN;
{中轨;灰色,股价站上此线才能出现妖股;
{★坑边信赖。原则:买低不买高。出现在金坑中或右侧边沿,距离右侧其他拉升放量信号越近越好!
出现在低位进入自选股一月内跟踪。无未来;例:2019年2月12日赫美集团;2019年5月16日金力永磁;
2018年11月1日和2019年2月18日市北高新;2019年2月11日国风塑业;2019年2月18日龙津药业;
2019年2月12日深南电A;2019年2月12日华菱星马;2017年11月29日泰禾集团;2019年6月12日电魂网络}
QFO3:=100-3*SMA((CLOSE-LLV(LOW,42))/(HHV(HIGH,42)-LLV(LOW,42))*100,5,1)
+2*SMA(SMA((CLOSE-LLV(LOW,42))/(HHV(HIGH,42)-LLV(LOW,42))*100,20,1),8,1);{42;15;21}
QFO4:=100-3*SMA((OPEN-LLV(LOW,66))/(HHV(HIGH,66)-LLV(LOW,66))*100,8,1)
+2*SMA(SMA((OPEN-LLV(LOW,66))/(HHV(HIGH,66)-LLV(LOW,66))*100,20,1),5,1);{66;20;15}
QFO5:=QFO3<REF(QFO4,1) AND VOL>REF(VOL,1) AND CLOSE>REF(CLOSE,1);
XG2C:=IF(QFO5 AND COUNT(QFO5,30)=1,20,0),STICK,LINETHICK2,COLORRED;
STICKLINE(XG2C,L*1.02,L*1.05,0.0001,0),COLORCYAN;
DRAWTEXT(C>REF(C,1) AND REF(RSI,1)>0 AND XG2C,L*1.05,'★坑边信赖'),COLORWHITE;
{▲主图有金坑吸筹,无金坑放弃。}
LCF:=REF(CLOSE,1);
RSI5:=((SMA(MAX((CLOSE - LCF),0),5,1) / SMA(ABS((CLOSE - LCF)),5,1)) * 100);
TR1F:=SUM(MAX(MAX((HIGH - LOW),ABS((HIGH - REF(CLOSE,1)))),ABS((LOW - REF(CLOSE,1)))),10);
HD:=(HIGH - REF(HIGH,1));
LD:=(REF(LOW,1) - LOW);
DMP:=SUM(IF(((HD > 0) AND (HD > LD)),HD,0),10);
DMM:=SUM(IF(((LD > 0) AND (LD > HD)),LD,0),10);
PDI:=((DMP * 100) / TR1F);
MDI:=((DMM * 100) / TR1F);
ADX:=MA(((ABS((MDI - PDI)) / (MDI + PDI)) * 100),5);
AV:=(RSI5 + ADX);
DXR:=(((ADX + REF(ADX,5)) / 2) + RSI5);
WR10:=((100 * (HHV(HIGH,60) - CLOSE)) / (HHV(HIGH,60) - LLV(LOW,60)));{10}
NEWVOL:=(RSI5 - WR10);
金坑买入:=(AV + NEWVOL);
买入选股:=IF(CROSS(金坑买入,0),1,0),STICK,COLORRED;{NODRAW}
VAR1Z:=SMA(买入选股,8,1);{3}
VAR2Z:=SMA(VAR1Z,8,1),COLOR0000FF;{3}
VAR3Z:=SMA(VAR2Z,10,1),COLOR00FFFF;{3}
金坑吸筹:=IF(CROSS(VAR2Z,VAR3Z) AND (VAR2Z<40),5,0* 10000),COLOR0000FF,LINETHICK1;{40}
STICKLINE(金坑吸筹,L*1.02,L*1.05,0.0001,0),COLORMAGENTA;
DRAWTEXT(金坑吸筹>0,L*1.03,'▲有金坑吸筹'),COLORLIRED;
{4、潜伏。无未来}
M5F:=MA(C,4);
M10F:=MA(C,8),COLORRED,LINETHICK2;
M20F:=MA(C,20);
{M30F:=MA(C,30);}
M60F:=MA(C,60),COLORBLUE,LINETHICK2;
D3:=MIN(MIN(M5F,M10F),M20F)>M60F;
LLM:=LLV("MACD.MACD"*100,200);
HHM:=HHV("MACD.MACD"*100,200);
TJA:=C>REF(C,1)*1.05;
T:=BARSLAST(C>REF(C,1)*1.095 AND C=H);
T2L:=BARSLAST(C<REF(C,1)*1.095 AND C>REF(C,1)*1.08);
T3L:=BARSLAST(C<REF(C,1)*1.08 AND C>REF(C,1)*1.07);
T4L:=BARSLAST(C<REF(C,1)*1.07 AND C>REF(C,1)*1.06);
T5L:=BARSLAST(C<REF(C,1)*1.06 AND C>REF(C,1)*1.05);
AAF1:=REF(T,1)>100 AND REF(T2L,1)>100 AND REF(T3L,1)>100 AND REF(T4L,1)>100 AND REF(T5L,1)>80 AND TJA;
XGT:=BARSLAST(AAF1 AND HHM<60 AND LLM>-55);
D6:=BARSSINCEN(MIN(MIN(M5F,M10F),M20F)>M60F,XGT+1);
XGX:=CROSS((XGT=0 AND D3) OR D6=0,0.5);
TJJ:=COUNT(XGX,30)=2 AND XGX;
SR1:=REF(HIGH,10)=HHV(HIGH,2*10+1);
SR2:=FILTER(SR1,10);
SR3:=REF(SR2,10+1);
HDF:=REF(SR3,10);
前高:=REF(H,BARSLAST(HDF));
倍量:=VOL/REF(VOL,1)>=1.9;
突破前高:=CROSS(C,前高);
YG:= 倍量 AND 突破前高;
低2:=IF(CURRBARSCOUNT<=60, CONST(IF(ISLASTBAR=1,LLV(L, BARSLAST(CURRBARSCOUNT=60)),1)),DRAWNULL);
SJ:=BARSLAST(YG);
DIF:=MACD.DIF;
H300:=HHVBARS(DIF,300);
AL:=BOLL.UB;
TQ:=BARSLAST(CROSS(AL>=REF(AL,1),0.5));
E25:=EXPMA(C,25);
ZF:=EVERY(RANGE(C/REF(C,1),0.97,1.05),TQ+1);
ZFF:=(HHV(H,TQ+1)-LLV(L,TQ+1))/LLV(L,TQ+1)*100;
TJQ:=EVERY(MAX(C,O)/AL<1.02 ,TQ+1);
XL:=(ATAN((E25/REF(E25,TQ)-1)*100)*180/3.1415926);
TJ1Q:=CROSS(DIF>=REF(DIF,H300),0.5) AND ZFF<17 AND ZF AND TJQ;
躁动:=TJ1Q AND XL>75;
A1F:=REF(C,1);
AYFF:=REF(C,10);
A31F:=(AYFF-A1F)/A1F*100;
AA1F:=(A31F-REF(A31F,1));
选股1:=CROSS(AAF1,9.8);
A11F:=REF(V,1);
VAR8:=IF(VOL/CAPITAL>0.001,1,EXP(ABS(LOG(VOL/CAPITAL*100))))>2;
A13F:=VAR8/A11F;
AA3F:=(A13F-REF(A13F,1));
选股2:=CROSS(AA3F,500);
潜伏2:=选股1 AND 选股2;
GX:=潜伏2 OR 躁动 OR CURRBARSCOUNT=CONST(SJ)+2 OR TJJ OR (CCI<=100 AND L<=低2);
准备:=FILTER(GX=1,3);
A2A:=BARSCOUNT(C);
AH:=HHV(H,200);
A1L:=LLV(L,200);
A0:=(AH-A1L)/190;
B1F:=L-A0;
STICKLINE(准备,B1F,B1F-10*A0,2,0),COLORGREEN;
DRAWTEXT(准备,H*0.95, '---潜伏'),COLORWHITE;
DRAWTEXT(飓风,L*0.96,'---飓风眼'),COLORWHITE;
{财神来敲门;有函数;不影响使用}
金童子:=C/REF(C,1)>1.048 AND C=H AND BETWEEN(FORCAST(V,4)
,0.2*FORCAST(V,12),2.1*FORCAST(V,12));{4;12;12}
财神:=FILTER(金童子,10);{58}
STICKLINE(财神,L*1.13,L*1.08,0.001,0),COLORWHITE;
DRAWTEXT(财神,L*1.13,'---财神来敲门'),COLORYELLOW;
DRAWICON(财神,L*1.13,9);
{乔治公爵的老枪准星之;杀手潜伏。无函数主图}
火弹:=MA(C,3),COLORRED,LINETHICK3;
弹夹:=MA(LOW,13)*1.2,COLORMAGENTA;
来福线:=MA(LOW,17)*1.1,COLORYELLOW;
{老炮筒1:MA(HIGH,100)*0.9,COLORWHITE;}
撞针:=MA(HIGH,13)*0.9,COLORWHITE;
扳机:=MA(HIGH,89)*0.8,COLORBROWN;
准星:=CROSS(火弹,撞针);
STICKLINE(准星,L*0.98,L*0.9,3,0),COLORLIMAGENTA;
DRAWTEXT(准星,L*0.9,'---杀手潜伏'),COLORWHITE;
{跃上金坑.与K线黄金坑配合使用。}
A1J:=ABS(((3.48*CLOSE+HIGH+LOW)/4-EMA(CLOSE,10))/EMA(CLOSE,10)); {23}
A2J:=DMA(((2.15*CLOSE+LOW+HIGH)/4),A1J);
金坑:=EMA(A2J,5)*1;{200}
金坑2:=EMA(A2J,200)*1.118;{200}
探路:=(C-REF(C,1))/REF(C,1)*100>8;
金库:=CROSS(C,金坑) AND 探路;
RRFJ:=金库,STICK;
STICKLINE(RRFJ,L*1,L*0.97,0.01,0),COLORRED;
DRAWTEXT(RRFJ,L*0.99,'-金坑迎财神'),COLORYELLOW;
DRAWTEXT(XG1P,L*1.1,'★坑后上涨'),COLORCYAN;
{涨停K}
AA:=REF(C,1)*1.1-C<0.01 AND H=C;
STICKLINE(AA,O,C,3,0),COLORFF11FF;
STICKLINE(AA,O,C,3,0),COLORFF33FF;
STICKLINE(AA,O,C,3,0),COLORFF55FF;
STICKLINE(AA,O,C,3,0),COLORFF77FF;
STICKLINE(AA,O,C,3,0),COLORFF99FF;
STICKLINE(AA,O,C,2,0),COLORFFBBFF;
STICKLINE(AA,O,C,1,0),COLORFFDDFF;
总股本:=STRCAT(STRCAT('总股本: ',CON2STR(TOTALCAPITAL/1000000,2)),'亿');
流通盘:=STRCAT(STRCAT(' 流通盘: ',CON2STR(CAPITAL/1000000,2)),'亿');
全流通:=STRCAT(' 全流通: ',CON2STR((CAPITAL/1000000)/(TOTALCAPITAL/1000000),2));
市值:=STRCAT(STRCAT(' 流通市值: ',CON2STR((CAPITAL/1000000)*C,2)),'亿');
BB1:=STRCAT('股本市值: ',STRCAT(STRCAT(STRCAT(总股本,流通盘),全流通),市值));
DRAWTEXT_FIX(ISLASTBAR,0.005,0.2,0,BB1),COLORMAGENTA;
{所属板块}
DRAWTEXT_FIX(1,0.005,0.00,0,'地区板块:')COLOR99CCFF;
DRAWTEXT_FIX(1,0.15,0.00,0,DYBLOCK)COLORGREEN;
DRAWTEXT_FIX(1,0.005,0.065,0,'概念板块:')COLOR99CCFF;
DRAWTEXT_FIX(1,0.15,0.065,0,GNBLOCK)COLORGREEN;
DRAWTEXT_FIX(1,0.005,0.12,0,'风格板块:')COLOR99CCFF;
DRAWTEXT_FIX(1,0.15,0.12,0,FGBLOCK)COLORGREEN;
A33:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;
A44:=SMA(A33,3,1;
A55:=SMA(A44,3,1);
A66:=3*A44-2*A55;
A77:=C-REF(C,1);
A88:=100*EMA(EMA(A77,6),6)/EMA(EMA(ABS(A77),6),6);
买:=LLV(A88,2)=LLV(A88,7) AND COUNT(A88<0,2) AND CROSS(A88,MA(A88,2));
DRAWTEXT(FILTER(买=1,5),LOW-0.25,'庄'),COLORWHITE;