DIF:EMA(CLOSE,12)-EMA(CLOSE,26);
DEA:EMA(DIF,9);
MACD:(DIF-DEA)*2,COLORSTICK;
AA:IF(DIF>DEA,DIF,DRAWNULL),colorred,LINETHICK2;
BB:IF(DEA>DIF,DIF,DRAWNULL),colorwhite,LINETHICK2;
CC:IF(DEA>DIF AND DIF>0,DIF,DRAWNULL),coloryellow,LINETHICK2;
STICKLINE(MACD>REF(MACD,1) AND MACD<0,0,MACD,8.5,0),colorred;
STICKLINE(MACD<REF(MACD,1) AND MACD>0,0,MACD,8.5,0),colorgreen;