{135均线}
VOLUME:VOL,VOLSTICK;
MAVOL1:MA(VOLUME,5)LINETHICK1,COLORFFFFFF;
MAVOL2:MA(VOLUME,135),LINETHICK1,COLORYELLOW;
{主力量能}
SHORT:=12;
LONG:=26;
MID:=9;
DIF:=EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);
DEA:=EMA(DIF,MID);
MACD:=(DIF-DEA)*2,COLORSTICK;
STICKLINE(DIF>DEA,0,VOL,2,0),COLORRED;
STICKLINE(DIF<DEA,0,VOL,2,0),COLORGREEN;
N:=9;
M1:=3;
M2:=3;
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;
STICKLINE(J>D,VOL/2,VOL,2,0),COLORRED;
STICKLINE(J<D,VOL/2,VOL,2,0),COLORGREEN;
{量能潮}
VA:=IF(CLOSE>REF(CLOSE,1),VOL,-VOL);
OBV1:=SUM(IF(CLOSE=REF(CLOSE,1),0,VA),0);
OBV2:=EMA(OBV1,3)-MA(OBV1,9);
OBV3:=EMA(IF(OBV2>0,OBV2,0),3);
MAC3:=MA(C,3);
STICKLINE(OBV3>REF(OBV3,1) AND MAC3>REF(MAC3,1),0,OBV3,0.5,0),COLORYELLOW;