{参数:P=5,M:=17}
P:=5;M:=17;MA1:MA(C,P),COLORRED;IF(MA1>REF(MA1,1),MA1,DRAWNULL),COLORRED;IF(MA1<REF(MA1,1),MA1,DRAWNULL),COLORGREEN;N:=10;M1:=5;M2:=20;RSV:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;K:=SMA(RSV,M1,1);D:=SMA(K,M2,1);J:=3*K-2*D;A:=CROSS(K,D);B:=CROSS(D,K);DRAWTEXT(A,H,'----------------'),COLOR0000FF;DRAWTEXT(B,L,'----------------'),COLOR00FF00;X:=(3*C+L+O+H)/6;控盘线:(20*X+19*REF(X,1)+18*REF(X,2)+17*REF(X,3)+16*REF(X,4)+15*REF(X,5)+14*REF(X,6)+13*REF(X,7)+12*REF(X,8)+11*REF(X,9)+10*REF(X,10)+9*REF(X,11)+8*REF(X,12)+7*REF(X,13)+6*REF(X,14)+5*REF(X,15)+4*REF(X,16)+3*REF(X,17)+2*REF(X,18)+REF(X,20))/210,COLORFF00FF;DD:=控盘线<REF(控盘线,1);IF(DD,控盘线,DRAWNULL),COLOR00FFFF;VAR21:=4*SMA((CLOSE-LLV(LOW,5))/(HHV(HIGH,5)-LLV(LOW,5))*100,5,1)-3*SMA(SMA((CLOSE-LLV(LOW,5))/(HHV(HIGH,5)-LLV(LOW,5))*100,5,1),3.2,1);VAR22:=8; QQ:=CROSS(VAR21,VAR22); DRAWICON(QQ,L*0.98,1);MID:=EMA(CLOSE,M);UPPER:MID+2*STD(CLOSE,M),COLORRED;LOWER:MID-2*STD(CLOSE,M),COLORBLUE;UPPER0:MID+3*STD(CLOSE,M),COLORRED;LOWER0:MID-3*STD(CLOSE,M),COLORBLUE;DRAWICON(HIGH>UPPER0 OR HIGH=UPPER0,HIGH*1.03,2);DRAWICON(LOW<LOWER0 OR LOW=LOWER0,LOW*0.99,1);选股:=LOW<LOWER0 OR LOW=LOWER0;