通达信MACD 四彩色 公式代码

DIFF:=(EMA(CLOSE,12) - EMA(CLOSE,26))*60,COLORFF17FF,LINETHICK2;

DEA:=EMA(DIFF,9),COLORFFFFFF,LINETHICK2;

MACD:=2*(DIFF-DEA), COLORSTICK;

STICKLINE(MACD>=0 AND MACD>=REF(MACD,1),0,MACD,4,1),COLOR0000A2;

STICKLINE(MACD>=0 AND MACD>=REF(MACD,1),0,MACD,3,1),COLOR0000BF;

STICKLINE(MACD>=0 AND MACD>=REF(MACD,1),0,MACD,2,1),COLOR0000DD;

STICKLINE(MACD>=0 AND MACD>=REF(MACD,1),0,MACD,1,1),COLOR0000FB;

STICKLINE(MACD>=0 AND MACD< REF(MACD,1),0,MACD,4,0),COLOR00A200;

STICKLINE(MACD>=0 AND MACD< REF(MACD,1),0,MACD,3,0),COLOR00BF00;

STICKLINE(MACD>=0 AND MACD< REF(MACD,1),0,MACD,2,0),COLOR00DD00;

STICKLINE(MACD>=0 AND MACD< REF(MACD,1),0,MACD,1,0),COLOR00FB00;

STICKLINE(MACD<0 AND MACD>=REF(MACD,1),0,MACD,4,1),COLOR00A2A2;

STICKLINE(MACD<0 AND MACD>=REF(MACD,1),0,MACD,3,1),COLOR00BFBF;

STICKLINE(MACD<0 AND MACD>=REF(MACD,1),0,MACD,2,1),COLOR00DDDD;

STICKLINE(MACD<0 AND MACD>=REF(MACD,1),0,MACD,1,1),COLOR00FBFB;

STICKLINE(MACD<0 AND MACD< REF(MACD,1),0,MACD,4,0),COLORA2A200;

STICKLINE(MACD<0 AND MACD< REF(MACD,1),0,MACD,3,0),COLORBFBF00;

STICKLINE(MACD<0 AND MACD< REF(MACD,1),0,MACD,2,0),COLORDDDD00;

STICKLINE(MACD<0 AND MACD< REF(MACD,1),0,MACD,1,0),COLORFBFB00;

(0)

相关推荐