DP:=EMA(EMA((INDEXC-LLV(INDEXL,34))/(HHV(INDEXH,34)-LLV(INDEXL,34))*100,3),3);
DD:=EMA(EMA((CLOSE-LLV(LOW,34))/(HHV(HIGH,34)-LLV(LOW,34))*100,3),3);
MM:=MA(DD,3);
强弱:=DD-DP;
STICKLINE(强弱>REF(强弱,1) AND 强弱>0,50,强弱+50,6,1),colorred;
STICKLINE(强弱<=REF(强弱,1) AND 强弱>0,50,强弱+50,6,0),colorred;
STICKLINE(强弱>REF(强弱,1) AND 强弱<0,50,强弱+50,6,1),colorwhite;
STICKLINE(强弱<=REF(强弱,1) AND 强弱<0,50,强弱+50,6,0),colorwhite;
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;
短:J,COLORFF00FF;
MJ:=MA(J,2);
中:DD,colorwhite;
均:MM,coloryellow;
DRAWICON(J>100 AND J<MJ,J,12);
DRAWICON(J<0 AND J>MJ,J,11);
DRAWICON(CROSS(J,0),J,5);
DRAWICON(CROSS(100,J),J,6);
主力:=DD;
趋势:=MM;
A333:=BARSLAST(REF(CROSS(主力,趋势),1));
B333:=REF(C,A333+1)>C AND REF(主力,A333+1)<主力 AND CROSS(主力,趋势);
A444:=BARSLAST(REF(CROSS(趋势,主力),1));
B444:=REF(C,A444+1)<C AND REF(趋势,A444+1)>主力 AND CROSS(趋势,主力);
底:=FILTER(B333>0,10);
顶:=FILTER(B444>0,10);
DRAWTEXT(底,趋势,'底'),coloryellow;
DRAWTEXT(顶,趋势,'顶'),coloryellow;