原理解析:
填充背景
DIFF赋值:(收盘价的6日指数移动平均 - 收盘价的14日指数移动平均)*100
输出DEA:DIFF的5日指数移动平均
输出平滑异同平均:2*(DIFF-DEA),COLORSTICK
当满足条件MACD0时,在0和MACD位置之间画柱状线,宽度为8,0不为0则画空心柱.,COLOR00AAFF
当满足条件MACD0时,在0和MACD位置之间画柱状线,宽度为6.6,0不为0则画空心柱.,COLOR00BBFF
当满足条件MACD0时,在0和MACD位置之间画柱状线,宽度为4.4,0不为0则画空心柱.,COLOR00CCFF
当满足条件MACD0时,在0和MACD位置之间画柱状线,宽度为3.3,0不为0则画空心柱.,COLOR00DDFF
当满足条件MACD0时,在0和MACD位置之间画柱状线,宽度为2.2,0不为0则画空心柱.,COLOR00EEFF
当满足条件MACD0时,在0和MACD位置之间画柱状线,宽度为1.1,0不为0则画空心柱.,COLOR00FFFF
当满足条件MACD>=1日前的MACDANDMACD>0时,在0和MACD位置之间画柱状线,宽度为8,0不为0则画空心柱.,COLOR0000AA
当满足条件MACD>=1日前的MACDANDMACD>0时,在0和MACD位置之间画柱状线,宽度为6.6,0不为0则画空心柱.,COLOR0011BB
当满足条件MACD>=1日前的MACDANDMACD>0时,在0和MACD位置之间画柱状线,宽度为4.4,0不为0则画空心柱.,COLOR0022CC
当满足条件MACD>=1日前的MACDANDMACD>0时,在0和MACD位置之间画柱状线,宽度为3.3,0不为0则画空心柱.,COLOR0033DD
当满足条件MACD>=1日前的MACDANDMACD>0时,在0和MACD位置之间画柱状线,宽度为2.2,0不为0则画空心柱.,COLOR0044EE
当满足条件MACD>=1日前的MACDANDMACD>0时,在0和MACD位置之间画柱状线,宽度为1.1,0不为0则画空心柱.,COLOR0055FF
当满足条件MACD>1日前的MACDANDMACD1日前的MACDANDMACD1日前的MACDANDMACD1日前的MACDANDMACD1日前的MACDANDMACD1日前的MACDANDMACD收盘价的6日简单移动平均 AND DIFF>=DEA ,自定色),线宽为3
PARTLINE(DIFF,收盘价>收盘价的6日简单移动平均 AND DIFF>=DEA ,自定色),线宽为3
PARTLINE(DEA,收盘价1,STRIP(RGB(70,100,255),RGB(110,130,255),1));
DIFF:=(EMA(CLOSE,6) - EMA(CLOSE,14))*100;
DEA:EMA(DIFF,5);
:2*(DIFF-DEA),COLORSTICK;
STICKLINE(MACD0,0,MACD,8,0 ),COLOR00aaff;
STICKLINE(MACD0,0,MACD,6.6,0 ),COLOR00bbff;
STICKLINE(MACD0,0,MACD,4.4,0 ),COLOR00ccff;
STICKLINE(MACD0,0,MACD,3.3,0 ),COLOR00ddff;
STICKLINE(MACD0,0,MACD,2.2,0 ),COLOR00eeff;
STICKLINE(MACD0,0,MACD,1.1,0 ),COLOR00ffff;
STICKLINE(MACD>=REF(MACD,1)AND MACD>0,0,MACD,8 ,0 ),COLOR0000aa;
STICKLINE(MACD>=REF(MACD,1)AND MACD>0,0,MACD,6.6 ,0 ),COLOR0011bb;
STICKLINE(MACD>=REF(MACD,1)AND MACD>0,0,MACD,4.4,0 ),COLOr0022cc;
STICKLINE(MACD>=REF(MACD,1)AND MACD>0,0,MACD,3.3 ,0 ),COLOR0033dd;
STICKLINE(MACD>=REF(MACD,1)AND MACD>0,0,MACD,2.2 ,0 ),COLOR0044ee;
STICKLINE(MACD>=REF(MACD,1)AND MACD>0,0,MACD,1.1 ,0 ),COLOR0055ff;
STICKLINE(MACD>REF(MACD,1)AND MACDREF(MACD,1)AND MACDREF(MACD,1)AND MACDREF(MACD,1)AND MACDREF(MACD,1)AND MACDREF(MACD,1)AND MACDMA(C,6) AND diff>=dea ,RGB(255,0,255)),linethick3;
PARTLINE(diff,C>MA(C,6) AND diff>=dea ,RGB(255,0,0)),linethick3;
PARTLINE(dea,CPARTLINE(diff,CTIPTEXT(ISNULL(REFX(CLOSE,1)),0,' '),colorred;
TIPTEXT(ISNULL(REF(CLOSE,1)),0,'');