买线:="KDJ.J#MONTH";
卖线:="KDJ.D#MONTH";
STICKLINE(买线>=卖线,REFDATE(HHV(H,0),DATE),REFDATE(LLV(L,0),DATE),6,0),COLOR001050;
卖线2:="KDJ.D#WEEK";
买线1:="KDJ.J#WEEK";
中国:=REF(买线,2)<-0.1 OR REF(买线,1)<-0.1 AND CROSS(买线,1) ;
STICKLINE(买线1<卖线2,REFDATE(HHV(H,0),DATE),REFDATE(LLV(L,0),DATE),6,0),COLORLIGREEN;
STICKLINE(买线<卖线,REFDATE(HHV(H,0),DATE),REFDATE(LLV(L,0),DATE),6,0),COLORBLUE;
MA1:MA(CLOSE,5);
突破:REF(EMA(C,5),1)COLORLIMAGENTA,LINETHICK2;
A1X:=(EMA(C,5)-突破)/突破*100,NODRAW;
出击:IF(A1X>=0,REF(EMA(C,5),BARSLAST(CROSS(A1X,0))+1),DRAWNULL)COLORYELLOW,LINETHICK2;
休假:IF(A1X<0,REF(EMA(C,5),BARSLAST(CROSS(0,A1X))+1),DRAWNULL)COLORGREEN,LINETHICK5;
STICKLINE(A1X<0,休假,突破,0,-1)COLORGREEN;
STICKLINE(C>0,休假,休假,20,200),COLORGREEN,LINETHICK5;
STICKLINE(休假>0,休假,休假,20,200),COLORRED,LINETHICK5;
※:IF(A1X<0,突破,DRAWNULL)COLORBLUE,LINETHICK2;
MA2:=MA(CLOSE,1);
OBV:=MA1;
P:=N;
A1:=REF(OBV,P)=HHV(OBV,2*P+1);
B1:=FILTER(A1,P);
C1:=BACKSET(B1,P+1);
D1:=FILTER(C1,P);{高点}
A2:=REF(OBV,P)=LLV(OBV,2*P+1);
B2:=FILTER(A2,P);
C2:=BACKSET(B2,P+1);
D2:=FILTER(C2,P);{低点}
上:REF(OBV,BARSLAST(D1)),COLORFF00FF,NODRAW;
下:REF(OBV,BARSLAST(D2)),COLOR00FF00,NODRAW;
向上:CROSS(OBV,上*1.01),NODRAW;
相对能量:(OBV-下)/(上-下)*100,COLORYELLOW,NODRAW;
R11:=BACKSET(ISLASTBAR,BARSLAST(D1)+1);
S11:=R11>REF(R11,1);
T11:=BACKSET(ISLASTBAR,BARSLAST(D2)+1);
U11:=T11>REF(T11,1);
VARK:MA1,COLORWHITE;
上升MA1:IF(VARK>REF(VARK,1),VARK,DRAWNULL),COLORRED,LINETHICK3;
走平MA1:IF(VARK=REF(VARK,1),VARK,DRAWNULL),COLORFFFFCC,LINETHICK3;
下降MA1:IF(VARK<REF(VARK,1),VARK,DRAWNULL),COLORGREEN,LINETHICK3;
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);
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR
VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),3,1),COLORRED;{红1}
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);
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR
VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),3,0),COLORFFCC66;
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;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),4,1),COLORYELLOW;
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;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),3,0),COLOR00FF00{98FD};
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),3,0),COLOR00C8FF;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),2,0),COLOR10ECFF;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),2,0),COLOR10FFFF;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),3,0),COLOR00D900;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),3,0),COLORBLUE;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),0,0),COLOR090FF2;
STICKLINE(MA1>突破,MA1,突破,1.0,0),COLORYELLOW;
STICKLINE(MA1<突破,MA1,突破,1.0,0),COLOR777777;
DRAWICON(CROSS(MA2,上*1.01),上,1);
DRAWICON(CROSS(OBV,上*1.01),上,11);
ZDF:=(C-REF(C,1))/REF(C,1)*100;
STICKLINE(ZDF<-9.9,O,C,1,0),COLORBLUE;
DRAWTEXT(CROSS(上*1.01,MA2),上,'走'),COLORYELLOW,LINETHICK8;
别外N设置为1/100/5
|