N:=5;
Q:=20;
短期:100*(C-LLV(L,N))/(HHV(C,N)-LLV(L,N));
中期:100*(C-LLV(L,2*N))/(HHV(C,2*N)-LLV(L,2*N));
中长期:100*(C-LLV(L,4*N))/(HHV(C,4*N)-LLV(L,4*N))COLORMAGENTA;
长期:100*(C-LLV(L,6*N))/(HHV(C,6*N)-LLV(L,6*N));
NOTEXT20:20,COLORLIGRAY,DOTLINE;
SB:=短期
XG:REF(SB,1) AND crOSS(C,REF(MAX(C,O),1)),COLORRED;
STICKLINE(XG,0,100,0.1,0),COLORRED;