通达信MACD 红绿柱面积(指标副图贴图)
通达信MACD副图指标 红柱面积 绿柱面积,需要看看,不喜欢的绕过。
DIFF:EMA(CLOSE,12)-EMA(CLOSE,26);
DEA:EMA(DIFF,9);
MACD:2*(DIFF-DEA),NODRAW;
MACDHS:=IF(MACD>0 AND MACD>REF(MACD,1),MACD,0);
MACDHX:=IF(MACD>0 AND MACD<REF(MACD,1),MACD,0);
MACDLX:=IF(MACD<0 AND MACD<REF(MACD,1),MACD,0);
MACDLS:=IF(MACD<0 AND MACD>REF(MACD,1),MACD,0);
STICKLINE(MACDHS>0,0,MACD,2,0),COLORRED;
STICKLINE(MACDHX>0,0,MACD,2,0),COLORYELLOW;
STICKLINE(MACDLX<0,MACD,0,2,0),COLORCYAN;
STICKLINE(MACDLS<0,MACD,0,2,0),COLORLIGREEN;
绿柱面积:10*IF (MACD<0,SUM(MACD,BARSLAST(MACD>0)),0),NODRAW,COLORCYAN;
红柱面积:10*IF (MACD>0,SUM(MACD,BARSLAST(MACD<0)),0),NODRAW,COLORRED;
DRAWNUMBER(REF(MACD,1)>0 AND MACD<=0 ,HHV(MACD,8),REF(红柱面积,1)),COLORRED;
DRAWNUMBER(REF(MACD,1)<0 AND MACD>=0 ,LLV(MACD,4),REF(ABS(绿柱面积),1)),COLORCYAN;
DRAWNUMBER(ISLASTBAR AND MACD<0,LLV(MACD,8),ABS(绿柱面积)),COLORCYAN;
DRAWNUMBER(ISLASTBAR AND MACD>0,HHV(MACD,4),ABS(红柱面积)),COLORRED;
- 上一篇公式:通达信金山谷主图指标 贴图
- 下一篇公式:通达信金钻系列之金钻香菇(指标副图选股贴图 实盘验证)