RSV:= (CLOSE-LLV(LOW,N1))/(HHV(HIGH,N1)-LLV(LOW,N1))*100;
K:=SMA(RSV,M1,1);
D:=SMA(K,M2,1);
J:=3*K-2*D;
longd:=cross(K,D);
longk:=cross(D,K);
buy(holding=0 and longd,1,market);
sell(holding=1 and longk,0,market);
buyshort(holding=0 and longk,1,market);
sellshort(HOLDING=-1 and longD,1,market);
sellshort(HOLDING=-1 and longD,1,market);
buy(holding=0 and longd,1,market);
sell(holding=1 and longk,0,market);
buyshort(holding=0 and longk,1,market);
这样写