通达信智慧MACD副图指标
VAR1:=(HIGH+LOW+CLOSE)/3;
DIFF:EMA(VAR1,25)-EMA(VAR1,99),LINETHICK0;
DEA:EMA(DIFF,17),LINETHICK0;
MACD:2*(DIFF-DEA),LINETHICK0;
VAR2:=DIFF;
VAR3:=DEA;
VAR4:=EMA(AMOUNT/(100*VOL),5);
VAR5:=EMA(AMOUNT/(100*VOL),13);
VAR6:=EMA(AMOUNT/(100*VOL),34);
VAR7:=DMA(CLOSE,VOL/CAPITAL);
VAR8:=(CLOSE-VAR5)/VAR5*100;
DRAWBAND(VAR2,RGB(220,100,0),VAR3,RGB(0,290,255));
IF(VAR2 >=REF(VAR2,1),VAR2,DRAWNULL),COLOR2B4AEC,LINETHICK0;
IF(VAR2 < REF(VAR2,1),VAR2,DRAWNULL),COLORGREEN,LINETHICK0;
IF(VAR3 >=REF(VAR3,1),VAR3,DRAWNULL),COLORRED,LINETHICK0;
IF(VAR3 < REF(VAR3,1),VAR3,DRAWNULL),COLORGREEN,LINETHICK0;
STICKLINE(MACD >=0 AND MACD >=REF(MACD,1),0,MACD,2,0),COLOR4D00D6;
STICKLINE(MACD >=0 AND MACD >=REF(MACD,1),0,MACD,1.5,0),COLOR4A00A4;
STICKLINE(MACD >=0 AND MACD >=REF(MACD,1),0,MACD,1,0),COLOR0000EE;
STICKLINE(MACD >=0 AND MACD >=REF(MACD,1),0,MACD,0.1,0),COLOR4A008E;
STICKLINE(MACD >=0 AND MACD >=REF(MACD,1),0,MACD,0,0),COLOR5200FF;
STICKLINE(MACD >=0 AND MACD < REF(MACD,1),0,MACD,2,0),COLOR6A6F60;
STICKLINE(MACD >=0 AND MACD < REF(MACD,1),0,MACD,1.5,0),COLOR936F60;
STICKLINE(MACD >=0 AND MACD < REF(MACD,1),0,MACD,1,0),COLORBE6F60;
STICKLINE(MACD >=0 AND MACD < REF(MACD,1),0,MACD,0.1,0),COLORBE9560;
STICKLINE(MACD >=0 AND MACD < REF(MACD,1),0,MACD,0,0),COLORBE957F;
STICKLINE(MACD < 0 AND MACD >=REF(MACD,1),0,MACD,2,0),COLOR520E4F;
STICKLINE(MACD < 0 AND MACD >=REF(MACD,1),0,MACD,1.5,0),COLOR520E59;
STICKLINE(MACD < 0 AND MACD >=REF(MACD,1),0,MACD,1,0),COLOR520E67;
STICKLINE(MACD < 0 AND MACD >=REF(MACD,1),0,MACD,0.1,0),COLOR520E89;
STICKLINE(MACD < 0 AND MACD < REF(MACD,1),0,MACD,2,0),COLOR155500;
STICKLINE(MACD < 0 AND MACD < REF(MACD,1),0,MACD,1.5,0),COLOR208000;
STICKLINE(MACD < 0 AND MACD < REF(MACD,1),0,MACD,1,0),COLOR2BAA00;
STICKLINE(MACD < 0 AND MACD < REF(MACD,1),0,MACD,0.1,0),COLOR35D500;
STICKLINE(MACD < 0 AND MACD < REF(MACD,1),0,MACD,0,0),COLOR40FF00;
DIF:EMA(VAR1,7)-EMA(VAR1,25);
DE:EMA(DIF,9);
MACDS:2*(DIF-DE),LINETHICK0;
IF(VAR8 > 0 AND VAR8 > REF(VAR8,1),DIF,DRAWNULL),COLORRED,LINETHICK2;
IF(CROSS(CLOSE,VAR6),DIF,DRAWNULL),COLORWHITE,LINETHICK2;
IF(CROSS(CLOSE,VAR7),DIF,DRAWNULL),COLORYELLOW,LINETHICK2;
IF(DIF > DE,DIF,DRAWNULL),COLORFFCC33,LINETHICK2;
IF(DIF < DE,DIF,DRAWNULL),DOTLINE,COLORWHITE;
IF(DIF > DE,DE,DRAWNULL),COLORGREEN,LINETHICK2;
IF(DIF < DE,DE,DRAWNULL),DOTLINE,COLORRED;
{买好股公式网WWW.BUYHAOGU.COM};