N:=9;M1:=3;M2:=3;
REFLINE: 0, 20, 50, 80, 100;
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;
VAR1:=WEEKDAY>REF(WEEKDAY,1);
VAR2:=WEEKDAY<REF(WEEKDAY,1);
上周收盘价:=REF(C,SUMBARS(VAR2,1));
上周开盘价:=REF(O,SUMBARS(VAR2,1));
上周交易天数:=SUMBARS(VAR2,2)-SUMBARS(VAR2,1);
上周最高价:=REF(H,SUMBARS(VAR2,1));
上周最低价:=REF(L,SUMBARS(VAR2,1));
ZRSV:=(CLOSE-MIN(LLV(LOW,SUMBARS(VAR2,1)),LLV(上周最低价,SUMBARS(VAR2,5))))
/(MAX(HHV(HIGH,SUMBARS(VAR2,1)),HHV(上周最高价,SUMBARS(VAR2,5)))-
MIN(LLV(LOW,SUMBARS(VAR2,1)),LLV(上周最低价,SUMBARS(VAR2,5))))*100;
ZK:SMA(ZRSV,SUMBARS(VAR2,3)-SUMBARS(VAR2,1),1),LINETHICK3;
ZD:SMA(ZK,SUMBARS(VAR2,3)-SUMBARS(VAR2,1),1),LINETHICK3;
ZJ:3*ZK-2*ZD,LINETHICK3;
80;
50;
20;