TT:=PERIOD=7;
EMA120:=EMA(C,120);
RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
J:=3*K-2*D;
DRAWTEXT(TT&&J<0,L,'多'),VALIGN0;
DRAWTEXT(TT&&J>100,H,'空'),VALIGN2;
IF(TT,EMA(C,60),NULL),RGB(255,255,255),NOTEXT;
DD:=J<0;
KK:=J>100;
DRAWSL(TT&&DD,C*(1-0.01),0,2,0,COLORGREEN),DOT;
DRAWSL(TT&&DD,C*(1-0.01),0,-2,0,COLORGREEN),DOT;
DRAWTEXT(TT&&DD,C*(1-0.01),'止损价'),COLORWHITE,VALIGN2;
DRAWNUMBER(TT&&DD,C*(1-0.01),C*(1-0.01),0,COLORWHITE),VALIGN0;
DRAWSL(TT&&KK,C*(1+0.01),0,2,0,COLORGREEN),DOT;
DRAWSL(TT&&KK,C*(1+0.01),0,-2,0,COLORGREEN),DOT;
DRAWTEXT(TT&&KK,C*(1+0.01),'止损价'),COLORWHITE,VALIGN0;
DRAWNUMBER(TT&&KK,C*(1+0.01),C*(1+0.01),0,COLORWHITE),VALIGN2;