股资源-股票学习站-学炒股-股票课程-炒股教程-分析选股指标-入门基础知识

 找回密码
 注册昵称

QQ登录

只需一步,快速开始

搜索
上一主题 下一主题

[通达信] 通达信彩色MACD无未来函数放心使用!


    [-----复制链接-----]
楼主
 通达信源码安装路径:1,工具栏点击公式选项。2,弹出公式窗口点击新建。3,把源码复制到指标编辑器保存。4,回到K线图界面安装建立好的公式 || 2023-10-9 11:40:42

以下是通达信彩色MACD无未来函数放心使用!

彩色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|

GMT+8, 2024-11-18 14:34

快速回复 返回顶部 返回列表