HIGHN:=10;LOWN:=10;HIGHDISPLAY:=0;LOWDISPLAY:=0;ZGDISPLAY:=0;MADISPLAY:=0;
AA:=REF(H,HIGHN)=HHV(H,2*HIGHN+1);
QY:=BACKSET(AA,HIGHN+1);
CC:=FILTER(QY,HIGHN) AND H=HHV(H,HIGHN+1);
DRAWICON(CC,H*1.02,2);
DDD:=BARSLAST(CC);
DINGBU:=IF(DDD,REF(H,DDD),H);{顶部}
DINGBU1:=REF(DINGBU,DDD+1);
DINGBU2:=REF(DINGBU1,DDD+1);
AA1:=REF(L,LOWN)=LLV(L,2*LOWN+1);
QY1:=BACKSET(AA1,LOWN+1);
CC1:=FILTER(QY1,LOWN) AND L=LLV(L,LOWN+1);
DRAWICON(CC1,L*0.98,1);
DD1:=BARSLAST(CC1);
YDB:=IF(DD1,REF(L,DD1),L);
ZDB:=REF(YDB,DD1+1);
s1:=IF(STKTYPE=0 OR STKTYPE=7,0.999,0.98);
s2:=IF(STKTYPE=0 OR STKTYPE=7,1.001,1.02);
MA06:MA(CLOSE,6),PRECISION2,COLOR00FFFF,LINEDOT;
MA18:MA(CLOSE,18),PRECISION2,COLOREEEEEE;
tj:=CLOSE>OPEN or CLOSE=OPEN and CLOSE>REF(CLOSE,1);
STICKLINE(tj and CLOSE>MA18,HIGH,LOW,0.1,0),colorred;
STICKLINE(tj and CLOSE>MA18,CLOSE,OPEN,7,0),colorred;
STICKLINE(NOT(tj) and CLOSE>MA18,HIGH,LOW,0.1,0),colorcyan;
STICKLINE(NOT(tj) and CLOSE>MA18,CLOSE,OPEN,7,0),colorcyan;
STICKLINE(tj and CLOSE<MA18,HIGH,LOW,0.1,0),colorred;
STICKLINE(tj and CLOSE<MA18,CLOSE,OPEN,7,1),colorred;
STICKLINE(NOT(tj) and CLOSE<MA18,HIGH,LOW,0.1,0),colorcyan;
STICKLINE(NOT(tj) and CLOSE<MA18,CLOSE,OPEN,7,1),colorcyan;
A1:=REF(H,8)=HHV(H,2*8+1);
B1:=FILTER(A1,8);
C1:=BACKSET(B1,8+1);
D1:=FILTER(C1,8);{高点}
R11:=BACKSET(ISLASTBAR,BARSLAST(D1)+1); S11:=R11>REF(R11,1);
DRAWLINE(D1,H,S11,H,1),COLORWHITE,lineDOT;
A2:=REF(L,8)=LLV(L,2*8+1);
B2:=FILTER(A2,8);
C2:=BACKSET(B2,8+1);
D2:=FILTER(C2,8);{低点}
T11:=BACKSET(ISLASTBAR,BARSLAST(D2)+1); U11:=T11>REF(T11,1);
DRAWLINE(D2,L,U11,L,1),COLORWHITE,lineDOT;
VAR1111:=BACKSET(REF(HIGH,2)=HHV(HIGH,5),3);
VAR2222:=CROSS(VAR1111,0.9);
VAR3333:=BACKSET(REF(LOW,2)=LLV(LOW,5),3);
VAR4444:=CROSS(VAR3333,0.9);
A1:=REF(H,8)=HHV(H,2*8+1);
B1:=FILTER(A1,8);
C1:=BACKSET(B1,8+1);
D1:=FILTER(C1,8);{高点}
R11:=BACKSET(ISLASTBAR,BARSLAST(D1)+1); S11:=R11>REF(R11,1);
DRAWLINE(D1,H,S11,H,1),COLORWHITE,lineDOT;
A2:=REF(L,8)=LLV(L,2*8+1);
B2:=FILTER(A2,8);
C2:=BACKSET(B2,8+1);
D2:=FILTER(C2,8);{低点}
T11:=BACKSET(ISLASTBAR,BARSLAST(D2)+1); U11:=T11>REF(T11,1);
DRAWLINE(D2,L,U11,L,1),COLORWHITE,lineDOT;
VAR1111:=BACKSET(REF(HIGH,2)=HHV(HIGH,5),3);
VAR2222:=CROSS(VAR1111,0.9);
VAR3333:=BACKSET(REF(LOW,2)=LLV(LOW,5),3);
VAR4444:=CROSS(VAR3333,0.9); |