MA1:=MA(CLOSE,5);
MA2:=MA(CLOSE,10);
MA3:=MA(CLOSE,20);
MA4:=MA(CLOSE,60);
MA5:=MA(CLOSE,120);
MA6:=MA(CLOSE,250);
昨天MA1:=REF(MA1,1);
昨天MA2:=REF(MA2,1);
昨天MA3:=REF(MA3,1);
昨天MA4:=REF(MA4,1);
昨天MA5:=REF(MA5,1);
昨天MA6:=REF(MA6,1);
SA:=MAX(MAX(MA1,MA2),MAX(MA3,MA4));
SB:=MIN(MIN(MA1,MA2),MIN(MA3,MA4));
多头N:=(昨天MA1>=昨天MA2 AND 昨天MA2>=昨天MA3 AND 昨天MA3>=昨天MA4 AND 昨天MA4>=昨天MA5 AND MA5>MA6 );
向上N:=(MA1>昨天MA1 AND MA2>昨天MA2 AND MA3>昨天MA3 AND MA4>昨天MA4 AND MA5>昨天MA5);
多头:=BARSLASTCOUNT(多头N>0)COLORWHITE,NODRAW;
向上:=BARSLASTCOUNT(向上N>0)COLORWHITE,NODRAW;
顺上:=多头>0 AND 向上>0;
四线粘合:=100*(SA-SB)/SB,COLORYELLOW,NODRAW;
四线粘合N:=BARSLASTCOUNT(四线粘合<5 and="" ma1="">MA2 AND MA4>MA5 );
W5:=COST(5);
W95:=COST(95);
90%集中:=(W95-W5)/COST(100)*100;
近:=REF(H,10)=HHV(H,10+1);
近高:=FILTER(近,10);
近H:=BACKSET(近高,10+1);
近高H:=FILTER(近H,10);
近高周期H:=REF(HIGH,BARSLAST(近高H));
远:=REF(H,20)=HHV(H,20+1);
远高:=FILTER(远,20);
远H:=BACKSET(远高,20+1);
远高H:=FILTER(远H,20);
远高周期H:=REF(HIGH,BARSLAST(远高H));
横盘突破:=CROSS(C,近高周期H) AND 四线粘合N>0 AND C>近高周期H ;
A1:=HHV(H,120);
A2:=LLV(L,120);
百二十日震幅:=(A1-A2)/A2*100;
百日换手:=SUM(VOL,100)*100/CAPITAL;
集中突破:=((百二十日震幅<100 AND 90%集中<15)*20 AND CROSS(C,近高周期H)) ;
钻K选股:=顺上 AND 四线粘合 AND 集中突破;
JL01:=MA(C,3);
LJL07:=(3*C+L+O+H)/6;
牛线:=(20*LJL07+19*REF(LJL07,1)+18*REF(LJL07,2)+17*REF(LJL07,3)+16*REF(LJL07,4)+15*REF(LJL07,5)+14*REF(LJL07,6)+13*REF(LJL07,7)+12*REF(LJL07,8)+11*REF(LJL07,9)+10*REF(LJL07,10)+9*REF(LJL07,11)+8*REF(LJL07,12)+7*REF(LJL07,13)+6*REF(LJL07,14)+5*REF(LJL07,15)+4*REF(LJL07,16)+3*REF(LJL07,17)+2*REF(LJL07,18)+REF(LJL07,20))/210,COLORRED;
趋势:MA(牛线,5),COLORMAGENTA,LINETHICK2;
MAH:=(H*18+REF(H,1)*17+REF(H,2)*16+REF(H,3)*15+REF(H,4)*14+REF(H,5)*13+REF(H,6)*12+REF(H,7)*11+REF(H,8)*10+REF(H,9)*9+REF(H,10)*8+REF(H,11)*7+REF(H,12)*6+REF(H,13)*5+REF(H,14)*4+REF(H,15)*3+REF(H,16)*2+REF(H,17)*1)/171;
MAL:=(L*18+REF(L,1)*17+REF(L,2)*16+REF(L,3)*15+REF(L,4)*14+REF(L,5)*13+REF(L,6)*12+REF(L,7)*11+REF(L,8)*10+REF(L,9)*9+REF(L,10)*8+REF(L,11)*7+REF(L,12)*6+REF(L,13)*5+REF(L,14)*4+REF(L,15)*3+REF(L,16)*2+REF(L,17)*1)/171;
趋势2:=(MAH+MAL)/2;
IF(趋势>趋势2,趋势,DRAWNULL),COLORCYAN,LINETHICK2;
{STICKLINE(多方<空方,LOW,HIGH,0,1),COLORGREEN;
STICKLINE(多方>空方,LOW,HIGH,0,1),COLORRED;
STICKLINE(((OPEN>CLOSE)AND(多方<空方)),(CLOSE-0.003),OPEN,3.1,0),COLORGREEN;
STICKLINE(((OPEN<CLOSE)AND(多方<空方)),CLOSE,OPEN,3.1,1),COLORGREEN;
STICKLINE(((OPEN>CLOSE)AND(多方>空方)),OPEN,(CLOSE-0.003),3.1,0),COLORRED;
STICKLINE(((OPEN
{阳线上下影}
STICKLINE(CLOSE>=OPEN,CLOSE,HIGH,0,0), COLORRED;
STICKLINE(CLOSE>=OPEN,OPEN,LOW,0,0), COLORRED;
{阴线上下影}
STICKLINE(CLOSE<OPEN,OPEN,HIGH,0,0), COLOR00EC00;
STICKLINE(CLOSE<OPEN,CLOSE,LOW,0,0), COLOR00EC00;
{阳K线}
STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,2.8.2,0),COLOR0000A1;
STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,1.9.2,0),COLOR0000B5;
STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,0.9.8,0),COLOR0000C5;
STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,0.4,0),COLOR0000D4;
STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,0.2,0),COLOR0000FF;
{阴K线}
STICKLINE(CLOSE<OPEN,CLOSE,OPEN,2.8.2,0),COLOR009000;
STICKLINE(CLOSE<OPEN,CLOSE,OPEN,1.9.2,0),COLOR00B400;
STICKLINE(CLOSE<OPEN,CLOSE,OPEN,0.9.8,0),COLOR00C100;
STICKLINE(CLOSE<OPEN,CLOSE,OPEN,0.4,0),COLOR00DB00;
STICKLINE(CLOSE<OPEN,CLOSE,OPEN,0.2,0),COLOR00EC00;
多线:=27;
空线:=55;
多方力度:=(3*SMA((CLOSE-LLV(LOW,多线))/(HHV(HIGH,多线)-LLV(LOW,多线))*100,5,1)-2*SMA(SMA((CLOSE-LLV(LOW,多线))/(HHV(HIGH,27)-LLV(LOW,多线))*100,5,1),3,1)),COLOR00FFFF,LINETHICK2;
空方力度:=100*(HHV(HIGH,空线)-CLOSE)/(HHV(HIGH,空线)-LLV(LOW,空线)),COLOR00EC00,LINETHICK1;
量比:=V/REF(V,1);
趋势线:=(MA(CLOSE,5)+MA(CLOSE,10)+MA(CLOSE,15)+MA(CLOSE,20))/4;
牛熊线:=MA(CLOSE,26);
生命线:=EMA(CLOSE,55);
成本线:=((COST(90)+COST(70)+COST(50)+COST(30)+COST(10))/5);
JD1:=MAX(MAX(趋势线,牛熊线),生命线);
JX1:=MIN(MIN(趋势线,牛熊线),生命线);
一阳定势:=(C>JD1 AND O
金银袋:=((C>生命线 AND 成本线>MA5 AND L <生命线 and="" c="">趋势线 AND CROSS(多方力度,空方力度) AND C/REF(C,1)>1.02 AND 量比>1.1 AND C>O AND H/MAX(O,C)<1.05));
红钻石:=(C/REF(C,1)>1.03 AND 量比>1 AND CROSS(多方力度,空方力度));
RSV:= (CLOSE-LLV(LOW,4))/(HHV(HIGH,4)-LLV(LOW,4))*100;
FASTK:=SMA(RSV,3,1);
龙K:=SMA(FASTK,2,1);
龙D:=SMA(龙K,5,1);
狗:=LLV(LOW,10);
年:=HHV(H,25);
到来:=EMA((C-狗)/(年-狗)*4,4);
抄底:=CROSS(到来,0.3);
龙行凤影:=3*SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100,5,1)
-2*SMA(SMA((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)
-LLV(LOW,27))*100,5,1),3,1);
底部区1:=龙行凤影<=10;
银K1:="趋势顶底.底部区域";
银K2:="龙腾四海.龙抬头";
DD1:=L>=REF(L,1) AND REF(L,1)<=REF(L,2) AND REF(L,1)=LLV(L,20);
DD2:=BACKSET(DD1,10)=0;
银K3:DD2 AND REF(DD1,1);
银K4:=底部区1>0 AND REF(底部区1,1)>0;
银K:(银K1+银K2+银K3+银K4),NODRAW;
STICKLINE(银K>1,LOW,HIGH,0,1)COLORWHITE;
STICKLINE(银K>1,C,O,3.4,0),COLOR999999;
STICKLINE(银K>1,C,O,2.2,0),COLORBBBBBB;
STICKLINE(银K>1,C,O,1.3,0),COLORDDDDDD;
STICKLINE(银K>1,C,O,0.8,0),COLORFFFFFF;
DRAWTEXT(银K>1,L,"---银K")COLORWHITE;
金K:一阳定势+金银袋,NODRAW;
STICKLINE(金K>=1,LOW,HIGH,0,1),COLORYELLOW;
STICKLINE(金K>=1,C,O,3.4,0),COLOR008888;
STICKLINE(金K>=1,C,O,3,0),COLOR00AAAA;
STICKLINE(金K>=1,C,O,2,0),COLOR00CCCC;
STICKLINE(金K>=1,C,O,1,0),COLOR00EEEE;
STICKLINE(金K>=1,C,O,0.3,0),COLOR00FFFF;
DRAWTEXT(金K>=1,L,"---金K")COLORYELLOW;
钻K:钻K选股+横盘突破;
STICKLINE(钻K>=1,LOW,HIGH,0,1),COLORMAGENTA;
STICKLINE(钻K>=1,C,O,3.4,0),COLORFF33FF;
STICKLINE(钻K>=1,C,O,3.2,0),COLORFF44FF;
STICKLINE(钻K>=1,C,O,3,0),COLORFF55FF;
STICKLINE(钻K>=1,C,O,2.5,0),COLORFF66FF;
STICKLINE(钻K>=1,C,O,2,0),COLORFF77FF;
STICKLINE(钻K>=1,C,O,1,0),COLORFF88FF;
STICKLINE(钻K>=1,C,O,0.5,0),COLORFF99FF;
DRAWTEXT(钻K>=1,L,"---钻K")COLORMAGENTA;
{顶K}
LC:= REF(CLOSE,1);
RSI:=SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100;
顶4:=CROSS(82,RSI);
顶1:=("趋势顶底.见顶");
顶3:=CROSS(3.5,到来);
顶K:(顶1+顶3+顶4),NODRAW;
STICKLINE(顶K>=3,LOW,HIGH,0,1)COLORCYAN;
STICKLINE(顶K>=3,C,O,3.4,0),COLORAAAA00;
STICKLINE(顶K>=3,C,O,3.0,0),COLORBBBB00;
STICKLINE(顶K>=3,C,O,2.4,0),COLORCCCC00;
STICKLINE(顶K>=3,C,O,2.0,0),COLORDDDD00;
STICKLINE(顶K>=3,C,O,1.6,0),COLOREEEE00;
STICKLINE(顶K>=3,C,O,1.2,0),COLORFFFF00;
STICKLINE(顶K>=3,C,O,0.6,0),COLORFFFF00;
DRAWTEXT(顶K>=3,H,"---顶K")COLORCYAN;
{顶量:=(VOL/REF(VOL,1))>3 AND C
STICKLINE(顶量>=1,LOW,HIGH,0,1)COLORCYAN;
STICKLINE(顶量>=1,C,O,3.4,0),COLORAAAA00;
STICKLINE(顶量>=1,C,O,3.0,0),COLORBBBB00;
STICKLINE(顶量>=1,C,O,2.4,0),COLORCCCC00;
STICKLINE(顶量>=1,C,O,2.0,0),COLORDDDD00;
STICKLINE(顶量>=1,C,O,1.6,0),COLOREEEE00;
STICKLINE(顶量>=1,C,O,1.2,0),COLORFFFF00;
STICKLINE(顶量>=1,C,O,0.6,0),COLORFFFF00;
DRAWTEXT(顶量>=1,H,"---顶K")COLORCYAN;};
品种类型:=FINANCE(3);
所属板块:=HYBLOCK;
上市天数:=FINANCE(42);
股总市值:=ROUND(FINANCE(41)/100000000);
流通市值:=ROUND(FINANCE(40)/100000000);
股东人数:=FINANCE(8);
人均持股:=ROUND(FINANCE(7)/FINANCE(8));
{}
DRAWTEXT_FIX(1,0.008,0.01,0,"基本资料:"),COLORFFCC99;
DRAWTEXT_FIX(1,0.008,0.05,0,"品种类型:"),COLOR99CCFF;
DRAWTEXT_FIX(1,0.008,0.09,0,"行业板块:"),COLOR99CCFF;
DRAWTEXT_FIX(1,0.008,0.13,0,"上市天数:"),COLOR99CCFF;
DRAWTEXT_FIX(1,0.008,0.17,0,"股东人数:"),COLOR99CCFF;
DRAWTEXT_FIX(1,0.008,0.21,0,"人均持股:"),COLOR99CCFF;
{}
DRAWTEXT_FIX(品种类型=1,0.065,0.05,0,"沪 深 A 股"),COLORWHITE;
DRAWTEXT_FIX(品种类型=2,0.065,0.05,0," 中 小 板"),COLORWHITE;
DRAWTEXT_FIX(品种类型=3,0.065,0.05,0," 创 业 板"),COLORWHITE;
DRAWTEXT_FIX(1,0.065,0.09,0,HYBLOCK),COLORWHITE;{行业板块}
{数值}
DRAWNUMBER_FIX(1,0.065,0.13,0,上市天数),COLORWHITE;
DRAWNUMBER_FIX(1,0.065,0.17,0,股东人数),COLORWHITE;
DRAWNUMBER_FIX(1,0.065,0.21,0,人均持股),COLORWHITE;
{单位}
{DRAWTEXT_FIX(1,0.09,0.13,0,"天"),COLORWHITE;
DRAWTEXT_FIX(1,0.09,0.17,0,"人"),COLORWHITE;
DRAWTEXT_FIX(1,0.09,0.21,0,"股"),COLORWHITE;}
{所属板块}
DRAWTEXT_FIX(1,0.008,0.25,0,"地区板块:")COLOR99CCFF;
DRAWTEXT_FIX(1,0.065,0.25,0,DYBLOCK)COLORWHITE;
DRAWTEXT_FIX(1,0.008,0.29,0,"概念板块:")COLOR99CCFF;
DRAWTEXT_FIX(1,0.065,0.29,0,GNBLOCK)COLORWHITE;
DRAWTEXT_FIX(1,0.008,0.33,0,"风格板块:")COLOR99CCFF;
DRAWTEXT_FIX(1,0.065,0.33,0,FGBLOCK)COLORWHITE;
DRAWTEXT_FIX(1,0.008,0.37,0,"自定板块:")COLOR99CCFF;
DRAWTEXT_FIX(1,0.065,0.37,0,ZDBLOCK)COLORWHITE;
DRAWTEXT_FIX(1,0.3,1,0,EXTERNSTR(0,1)),COLORWHITE,LINETHICK2;