彩色MACD通达信公式 副图 源码附图无未来函数

DIFIF1:=EMA(CLOSE,12) - EMA(CLOSE,26);
DEAEA1:=EMA(DIFIF1,9);
MACD1:=2*(DIFIF1-DEAEA1),STICK;
MACD2:=EMA(MACD1,3);
STICKLINE(MACD1>MACD2 AND MACD1>0,0,MACD1,0.2,0),COLORRED;
STICKLINE(MACD1>MACD2 AND MACD1<0,0,MACD1,0.2,0),COLORGREEN;
STICKLINE(MACD1<MACD2,0,MACD1,0.2,0),COLORCBCBC0;
STICKLINE(MACD1>=0 OR MACD1<=0,0,0,20,1),COLORWHITE;
DIFIF1,COLOR33FF33,LINETHICK1;
DEAEA1,COLORYELLOW,LINETHICK1;
MACD:MACD1,NODRAW,COLORMAGENTA;
DRAWTEXT(CROSS(DIFIF1,DEAEA1) AND DIFIF1<1,DIFIF1,'↑买'),LINETHICK1, COLORYELLOW;
DRAWTEXT(CROSS(DEAEA1,DIFIF1)AND MACD<REF(MACD,1),DEAEA1,'↓卖'),LINETHICK1, COLORGREEN;
红面积:IF(DIFIF1>DEAEA1,SUM(MACD,BARSLAST(CROSS(DIFIF1,DEAEA1))),DRAWNULL),NODRAW,COLORLIRED;
绿面积:IF(DIFIF1<DEAEA1,SUM(MACD,BARSLAST(CROSS(DEAEA1,DIFIF1))),DRAWNULL),NODRAW,COLORGREEN;
DRAWNUMBER(CROSS(DIFIF1,DEAEA1),DEAEA1,REF(绿面积,1)),COLORGREEN;
DRAWNUMBER(CROSS(DEAEA1,DIFIF1),DEAEA1*1.1,REF(红面积,1)),COLORLIRED;
DRAWNUMBER(DIFIF1>DEAEA1,MACD,BARSLAST(CROSS(DIFIF1,DEAEA1))+1),COLORRED;
DRAWNUMBER(DIFIF1<DEAEA1,MACD,BARSLAST(CROSS(DEAEA1,DIFIF1))+1),COLORCYAN;
DIF:=EMA(C+SLOPE(C,12),12)-EMA(C+SLOPE(C,26),26),COLORWHITE;
DEA:=EMA(DIF+SLOPE(DIF,6),6),COLORGREEN;
SDEA:REF(HHV(DEA,BARSLAST(CROSS(DEA,DIF))+1),1),COLORMAGENTA;
BDEA:REF(LLV(DEA,BARSLAST(CROSS(DIF,DEA))+1),1),COLORAAAA00;
CD:MACD,COLORCYAN;
涨CD:IF(CD>REF(CD,1),CD,DRAWNULL),COLORRED,LINETHICK1;
涨DIFIF1:IF(DIFIF1>REF(DIFIF1,1),DIFIF1,DRAWNULL),COLORRED,LINETHICK1;
A1:=BARSLAST(REF(CROSS(DIFIF1,DEAEA1),1));
多空分界线:0,COLORGREEN;



来函数检测结果如下:
该公式没有未来函数

解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式

联系我们  |  指标公式网  |  指标网   |  指标公式  |   加入收藏   |  设为主页

@2005-2023 浙ICP备2024071487号-2 指标公式网别名指标网仅为互联网文章,所有指标公式及文章仅供学习研究,并不构成投资建议,请勿以此为依据进行股票交易,由此引起的投资亏损与本站无关。指标公式网均来源互联网收集整理,如不慎侵犯了你的权益,请联系我们告知,我们将做删除处理
QQ:88652583 微信 88652583
sitemap站点地图