input:N(130,1,10000),M(50,0,100);
DRAWTEXTABS(300,10,'买入原则:突围看五阳出水;大牛股看调整评台季量'),color00FFFF;
DIFF:=( EMA(CLOSE,7) - EMA(CLOSE,19));
DEA:=EMA(DIFF,9);
MACD:=0.90*(DIFF-DEA);
tj:=(diff>=dea);
tj1:=(diff>=0);
Var1:=(CLOSE*2+HIGH+LOW)/4;
SK:= EMA(Var1,13)-EMA(Var1,73);
SD:= EMA(SK,2);
周:MA(C,5),COLORRED,LINETHICK2;
K1:=BACKSET(周<REF(周,1),2);
PARTLINE(周,K1),COLOR00CC33,LINETHICK2;
二周:MA(C,10),COLORRED,LINETHICK2;
K2:=BACKSET(二周<REF(二周,1),2);
PARTLINE(二周,K2),COLOR00CC33,LINETHICK2;
月:MA(C,30),COLOR9933CC,LINETHICK2;
K3:=BACKSET(月<REF(月,1),2);
PARTLINE(月,K3),COLORFFFFFF,LINETHICK2;
季:MA(C,60),COLORCYAN,LINETHICK1;
K4:=BACKSET(季<REF(季,1),2);
{PARTLINE(季,K4),COLOR00FFFF,LINETHICK1;}
半年:MA(C,120),CIRCLEDOT,COLOR6699FF,LINETHICK0;
K5:=BACKSET(半年<REF(半年,1),2);
PARTLINE(半年,K5),CIRCLEDOT,COLORFFFFCC,LINETHICK1;
{年:MA(C,240),COLOR0000FF,CROSSDOT,LINETHICK1;
K6:=BACKSET(年<REF(年,1),2);
PARTLINE(年,K6),COLOR00FF00,CROSSDOT,LINETHICK1;
二年:MA(C,480),COLOR00FFFF,CROSSDOT,LINETHICK1;
K7:=BACKSET(二年<REF(二年,1),2);
PARTLINE(二年,K7),COLOR006633,CROSSDOT,LINETHICK1;
三年:MA(C,720),COLORFF00FF,CROSSDOT,LINETHICK1;
K8:=BACKSET(三年<REF(三年,1),2);
PARTLINE(三年,K8),COLORFF9900,CROSSDOT,LINETHICK1;}
MA4:MA(CLOSE,4),PRECIS2;
{分时图中引用4日}
MA4:="MAB.MA4#day";
{计算均线在分时图中占位}
MA4P:=(MA4-DYNAINFO(3))/DYNAINFO(3)*100;
{设置是否显示标志}
zt:=1.1*DYNAINFO(3);
dt:=0.9*DYNAINFO(3);
MA4S:=MA4>dt and MA4<zt;
{画日线};
{if(MA4S,MA4,DYNAINFO(7)),DOTLINE,colorwhite;}
WXJDZ:=MAX(MA(C,5),MAX(MAX(MA(C,10),MA(C,20)),MAX(MA(C,60),MA(C,120))));
SXJDZ:=MAX(MA(C,5),MAX(MAX(MA(C,10),MA(C,20)),MA(C,60)));
WXD1Y:=CROSS(C,WXJDZ);
SXD1Y:=CROSS(C,SXJDZ);
五线第一阳:=(WXD1Y AND COUNT(WXD1Y,30)=1) OR (SXD1Y AND COUNT(SXD1Y,20)=1) AND ((C-REF(C,1))/REF(C,1)>=0.03);
DRAWTEXT(五线第一阳,L-0.1,'▲五线第一阳'),COLORYELLOW;
{MA5:=MA(CLOSE,5);
MA10:=MA(CLOSE,10);
MA20:=MA(CLOSE,20);
MA40:=MA(CLOSE,40);
MA60:=MA(CLOSE,60);
MA120:=MA(CLOSE,120);
AA:=BARSLAST(MA60>MA40 AND (MA40=MA20 OR MA40>MA20));
BB:=REF(COUNT(C<MA60,AA)=AA,1);
CC:=CROSS(C,MA60) AND VOL>MA(VOL,5) AND (C-REF(C,1))/REF(C,1)*100>3;
芙蓉出水:=BB AND CC;
DRAWTEXT(芙蓉出水,c-0.2,'▲芙蓉出水'),COLORWHITE;
月价托:=ma5>ma20 and ma5>ma10 and cross(ma10,ma20);
季价托:=ma20>ma60 and ma20>ma40 and cross(ma40,ma60) ;
短、长价托:=ma5>ma60 and ma5>ma10 and cross(ma10,ma60);
drawtext(月价托,l-0.1,'月'),coloryellow,ALIGN0;
drawtext(月价托,l-0.3,'价'),coloryellow,ALIGN0;
drawtext(月价托,l-0.5,'托'),coloryellow,ALIGN0;
stickline(月价托,l,h,0.5,1), coloryellow;
stickline(月价托,o,c,5,1),linethick3, coloryellow;
drawtext(季价托,l,'季'),colorf00ff0,ALIGN0;
drawtext(季价托,l-0.4,'价'),colorf00ff0,ALIGN0;
drawtext(季价托,l-0.7,'托'),colorf00ff0,ALIGN0;
stickline(季价托,l,h,0.5,1), colorf00ff0;
stickline(季价托,o,c,5,1),linethick3, colorf00ff0;
drawtext(短、长价托,l,'短、长价托'),color36c0c1;
stickline(短、长价托,l,h,0.5,1), color36c0c1;
stickline(短、长价托,o,c,5,0),linethick3;
vol1:=MA(VOL,5);
vol2:=MA(VOL,10);
vol3:=MA(VOL,20);
量托:=vol1>=vol3 and cross(vol2,vol3) and ref(vol2,1)<ref(vol3,1);
drawtext(量托,l,'▲'),colorwhite;
drawtext(量托,l-0.2,'量'),colorwhite;
drawtext(量托,l-0.3,'托'),colorwhite;
stickline(量托,l,h,0.5,1), colorwhite;
stickline(量托,o,c,5,1),linethick3, colorwhite;}
drawtext((cross(sk,sd) and sk<-0.04 and(c-ref(c,1))/ref(c,1)>=0.03) or (cross(sk,sd) and sk<=-0.14 )
or (cross(sk,sd) and sk<=0.05 and(v/ma(v,5)>2 or c/ref(c,1)>0.035)) ,l*0.99,'短线'),colorgreen;
stickline((cross(sk,sd) and sk<-0.04 and(c-ref(c,1))/ref(c,1)>=0.03) or (cross(sk,sd) and sk<=-0.14 )
or (cross(sk,sd) and sk<=0.05 and(v/ma(v,5)>2 or c/ref(c,1)>0.035)),h,l,0.5,0),colorred;
stickline((cross(sk,sd) and sk<-0.04 and(c-ref(c,1))/ref(c,1)>=0.03) or (cross(sk,sd) and sk<=-0.14 )
or (cross(sk,sd) and sk<=0.05 and(v/ma(v,5)>2 or c/ref(c,1)>0.035)),o,c,10,1),linethick3,colorred; |