MA1:MA(CLOSE,M1);
MA2:MA(CLOSE,M2);
MA3:MA(CLOSE,M3);
MA4:MA(CLOSE,M4);
MA5:MA(CLOSE,M5);
KPD1:=EMA(EMA(CLOSE,9),9);
KPD2:=100*WINNER(CLOSE*0.95);
L1:=(EMA(CLOSE,3) - EMA(CLOSE,13));
L2:=EMA(L1,9);
L3:=BARSLAST(CROSS(L1,L2));
L4:=REF(L3,L3+1);
L5:=L2;
ROC:=(CLOSE-REF(CLOSE,21))/REF(CLOSE,21)*100;
AC:=AMOUNT/(VOL);
YY:=MA(AC,13);
LLL:=(C-YY)/YY*100;
MIDC:=MA(CLOSE,22);
UPPERC:=MIDC+2*STD(C,22);
LOWERC:=MIDC-2*STD(C,22);
BBA:=(C-LOWERC)/(UPPERC-LOWERC);
LIFENGCYC:=(REF(LLL,1)<-15 AND REF(BBA,1)<0 AND LLL>REF(LLL,1));
控盘:=(KPD1-REF(KPD1,1))/REF(KPD1,1)*1000;
启动:STICKLINE(IF(CROSS(控盘,0),10,0),O,C,0.5,0),COLOR00FFFF;
拐点:STICKLINE(FILTER(CROSS(ROC,0),6),O,C,0.5,0),COLORFF8080;
变盘:STICKLINE(CROSS(L1,L2) AND L5,O,C,0.5,0),COLOR0080FF;
DRAWTEXT_FIX(1,0.0,0,0,'细K线颜色:黄-启动 桔黄-变盘 紫兰-拐点 红-买点 //粗K线颜色:橙黄-买 粉红-卖 //∠45升次日高开抱,低开出 //红←买 绿←卖'),COLOR00FFFF;
MID:=(3*CLOSE+LOW+OPEN+HIGH)/6;
VAR111:=EMA(CLOSE,4)-EMA(CLOSE,13);
AA222:=VAR111>=REF(VAR111,1);
BB222:=VAR111<REF(VAR111,1);
买入:DRAWICON(CROSS(AA222,BB222),L*0.993,38);
卖出:DRAWICON(CROSS(BB222,AA222),H*1.004,39);
JRH:=HHV(C,2);
JRL:=LLV(C,2);
YTSL:=(3*CLOSE+LOW+OPEN+HIGH)/6;
VAR1:=(CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2));
VAR2:=(REF(VAR1,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VAR3:=(REF(VAR2,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VAR4:=(REF(VAR3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VAR5:=(REF(VAR4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VAR6:=(REF(VAR5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VAR7:=(REF(VAR6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VAR8:=(REF(VAR7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VAR9:=(REF(VAR8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VARA:=(REF(VAR9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VARB:=(REF(VARA,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VARC:=(REF(VARB,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VARD:=(CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2));
VARE:=(REF(VARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VARF:=(REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VAR10:=(REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VAR11:=(REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VAR12:=(REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VAR13:=(REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VAR14:=(REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VAR15:=(REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VAR16:=(REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VAR17:=(REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
VAR18:=(REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
VAR19:=((REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1)) AND VAR1);
VAR1A:=((REF(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,1)) AND VARD);
短买:VAR19,COLOR33AACC,NODRAW;
品红离场:VAR1A,COLORFF99FF,NODRAW;
急速超跌:(CLOSE-MA(CLOSE,34))/MA(CLOSE,34)*100<-14,COLORFFFFFF,NODRAW;
CO:=(C-O);
STICKLINE(急速超跌,O,C-CO/2,2.8,0),COLOR555555;
STICKLINE(急速超跌,O,C-CO/2,2,0),COLOR888888;
STICKLINE(急速超跌,O,C-CO/2,1.5,0),COLORAAAAAA;
STICKLINE(急速超跌,O,C-CO/2,1,0),COLORCCCCCC;
STICKLINE(急速超跌,O,C-CO/2,0.5,0),COLOREEEEEE;
STICKLINE(短买,O,O+CO/3,2,0),COLOR335555;
STICKLINE(短买,O,O+CO/3,2,0),COLOR338888;
STICKLINE(短买,O,O+CO/3,1.5,0),COLOR33AAAA;
STICKLINE(短买,O,O+CO/3,1,0),COLOR33CCCC;
STICKLINE(短买,O,O+CO/3,0,0),COLOR33EEEE;
DRAWTEXT(短买,REF(CLOSE,1)-0.04,''),COLOR33FFCC;
STICKLINE(品红离场,O,O+CO/3,2,0),COLOR550055;
STICKLINE(品红离场,O,O+CO/3,0.1,0),COLOR880088;
STICKLINE(品红离场,O,O+CO/3,1.5,0),COLORAA00AA;
STICKLINE(品红离场,O,O+CO/3,1,0),COLORCC00CC;
STICKLINE(品红离场,O,O+CO/3,0.5,0),COLOREE00EE;
DRAWTEXT(品红离场,REF(CLOSE,1)+0.07,''),COLORFF99FF;
MA18:=MA(CLOSE,18);
MTM:=C-REF(C,1);
DX:=100*EMA(EMA(MTM,6),6)/EMA(EMA(ABS(MTM),6),6);
买:=LLV(DX,2)=LLV(DX,7) AND COUNT(DX<0,2) AND CROSS(DX,MA(DX,2));
DRAWTEXT(FILTER(买=1,5),L*0.993,'←'),COLORRED;
卖一:=HHV(DX,2)=HHV(DX,7) AND COUNT(DX>50,2) AND CROSS(MA(DX,2),DX);
DRAWTEXT(FILTER(卖一=1,1),HIGH*1.016,'←'),COLORGREEN;
XXS:=MA(LOW,5)*(1-5/100);
XXS1:=MA(HIGH,5)*(1+5/100);
均线:=C,COLORGREEN;
BBAA:=CROSS(XXS1,C);
DRAWTEXT(CROSS(XXS1,C),L*0.98,'←开逃'),COLORWHITE;
DDDD:=CROSS(C,XXS1);
DRAWTEXT(DDDD,L*0.98,'←明走'),COLORYELLOW;
X1:=(C+L+H)/3;
BB13:=ATAN(EMA(X1,13)-REF(EMA(X1,13),1))*3.1416*10;
EMA8:=EMA(C,8);
DRAWTEXT(FILTER(BB13>1 AND EMA(X1,13)>REF(EMA(X1,8),1),10),
EMA8,'★∠45升'),COLORLIBLUE;
VAR27:=REF(CLOSE,1);
VAR28:=SMA(MAX(CLOSE-VAR27,0),5.5,1)/SMA(ABS(CLOSE-VAR27),6,10)*100;
DRAWTEXT((IF(CROSS(76,VAR28),1,0)) OR CROSS(84,RSI),H*0.97,'莫贪') ,COLORYELLOW;
VAR4A:=EMA(CLOSE,3);
DRAWICON(COUNT(REF(VAR4A,1)<REF(VAR4A,2),5)=5 AND VAR4A>REF(VAR4A,1),L*0.98.5,36);
X8:="MACD.MACD";
XA:=HHV(REF(X8,1),BARSLAST(X8>0)+1);
A8:=(X8/REF(X8,1)-1)*100;
A1:=BARSLAST(CROSS(0,A8))+1;
DRAWTEXT(X8>0.618 AND CROSS(XA,X8),H*1.02,'止赢'),COLORBLUE;
STICKLINE(X8>0.618 AND CROSS(XA,X8),H*1.02,H*1.021,20,1),COLORBLUE;
DRAWTEXT(REF(C,BARSLAST(REF(CROSS("MACD.DIF","MACD.DEA"),1))+1)>C AND
REF("MACD.DIF",BARSLAST(REF(CROSS("MACD.DIF","MACD.DEA"),1))+1)
<"MACD.DIF" AND CROSS("MACD.DIF","MACD.DEA")
>0,L-0.02,'★M'),COLORFF00FF;{MACD底背离}
DRAWTEXT(REF(C,BARSLAST(REF(CROSS("KDJ.K","KDJ.D"),1))+1)>C AND
REF("KDJ.K",BARSLAST(REF(CROSS("KDJ.K","KDJ.D"),1))+1)<"KDJ.K" AND
CROSS("KDJ.K","KDJ.D"),L-0.10,'◎K'),COLORFF00FF;{KDJ底背离}
DRAWTEXT(REF(C,BARSLAST(REF(CROSS("RSI.RSI1","RSI.RSI2"),1))+1)>C AND
REF("RSI.RSI1",BARSLAST(REF(CROSS("RSI.RSI1","RSI.RSI2"),1))+1)
<"RSI.RSI1" AND CROSS("RSI.RSI1"," |