DIFF:=EMA(CLOSE,12) - EMA(CLOSE,26);
DEA:=EMA(DIFF,9);
macd:=2*(DIFF-DEA);
H9:=HHV(C,9),LINETHICK1,COLORGRAY;
L9:=LLV(C,9),LINETHICK1,COLORGRAY;
DRAWBAND(H9,RGB(255,217,40),L9,RGB(255,255,255));
STICKLINE(MacD<0 OR (DIFF<0 AND MACD>=0),H9,L9,3.8,0),COLORFEFBC9;
G:H9,COLORLIGRAY;
D:L9,COLORLIGRAY;
RSV9:=MA((CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100,3);
K9:=SMA(RSV9,3,1),COLORBLACK,LINETHICK1;
D9:=SMA(K9,2,1),COLOR009500,LINETHICK1;
J9:=2*K9-1*D9,COLORRED,LINETHICK1;
K:=J9;
YYCXTJ:=crOSS(K,80);
YYCXT:=BArslAST(YYCXTJ);
YYCXTO:=REF(O,YYCXT);
多方防守位:=YYCXTO,COLORRED,LINETHICK1;
YYCXT1:=REF(C,YYCXT);
多方防守位1:YYCXT1,COLORRED,LINETHICK1,DOTLINE;
空头排列:=CROSS(20,K);
KT:=BARSLAST(空头排列);
空头:=REF(O,KT);
空方防守位:=空头,COLORBLUE,LINETHICK1;
空头1:=REF(C,KT);
空方防守位1:空头1,COLORBLUE,LINETHICK1,DOTLINE;
MA9:=MA(CLOSE, 9),COLORMAGENTA,LINETHICK1;
平衡线:MA9,COLORMAGENTA,LINETHICK1;
震荡线:LLV(平衡线,2),COLORBLACK,LINETHICK1;
持股线:平衡线-(震荡线-平衡线),COLORBLACK,LINETHICK1;
STICKLINE(C<=O,OPEN,CLOSE,2,0),COLOR009500;
STICKLINE(C<=O,H,L,0,0),COLOR009500;
STICKLINE(C>O,O,C,2,0),COLORRED;
STICKLINE(C>O,H,L,0,0),COLORRED;
H45:HHV(C,45),LINETHICK1,COLORBLUE;
L45:LLV(C,45),LINETHICK1,COLORBLUE;