RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
W:=-100*(HHV(HIGH,100)-CLOSE)/(HHV(HIGH,100)-LLV(LOW,100));
W1:=-100*(HHV(HIGH,52)-CLOSE)/(HHV(HIGH,52)-LLV(LOW,52));
VAR1:=CLOSE>OPEN AND D>15 AND K>12 AND D<82 AND K<88;
VAR2:=NOT(VAR1) AND D<15 AND K<12;
VAR3:=NOT(VAR1 OR VAR2) AND D>82 AND K>88;
VAR4:=NOT(VAR1 OR VAR2 OR VAR3) AND W>-0.01;
VAR5:=NOT(VAR1 OR VAR2 OR VAR3 OR VAR4) AND W1<-99.9;
VAR6:=NOT(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5);
STICKLINE(VAR1,0,10,2,1),COLORRED;
STICKLINE(VAR2,0,10,2,1),COLORYELLOW;
STICKLINE(VAR3,0,10,2,1),COLORGREEN;
STICKLINE(VAR4,0,10,2,1),COLORBLUE;
STICKLINE(VAR5,0,10,2,1),COLORWHITE;
STICKLINE(VAR6,0,10,2,1),COLORGREEN;