DIF:EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);
DEA:EMA(DIF,MID);
MACD:(DIF-DEA)*2,COLORSTICK;
STICKLINE(DIF<0 AND CROSS(DIF,DEA),DEA,0,1,0),colorred;
STICKLINE(DIF>0 AND CROSS(DEA,DIF),DEA,0,1,0),colorgreen;
STICKLINE(DIF<0 AND CROSS(DIF,DEA),DEA,0,1,0),colorred;
STICKLINE(DIF>0 AND CROSS(DEA,DIF),DEA,0,1,0),colorgreen;
DRAWTEXT(DIF<0 AND CROSS(DIF,DEA),DEA/2,'--------------'),colorgreen;
DRAWTEXT(DIF>0 AND CROSS(DEA,DIF),DEA/2,'--------------'),colorred;
NOTEXT_1:IF(DIF<0,DIF,0),colorred,LINETHICK2;
NOTEXT_2:IF(DIF<0,0,DIF),coloryellow,LINETHICK2;
NOTEXT_3:IF(DIF<DEA,DIF,DEA),COLOR00FF00,LINETHICK2;
NOTEXT_4:IF(DIF>DEA,DEA,DEA),colorwhite,LINETHICK2;