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

 找回密码
 注册昵称

QQ登录

只需一步,快速开始

搜索
上一主题 下一主题

[通达信] 通达信大行情牛启动副图指标长短周期MACD改版


    [-----复制链接-----]
楼主
 通达信源码安装路径:1,工具栏点击公式选项。2,弹出公式窗口点击新建。3,把源码复制到指标编辑器保存。4,回到K线图界面安装建立好的公式 || 2024-6-4 09:12:26
{大行情牛启动}


DIF:((EMA(CLOSE,48)-EMA(CLOSE,104))),COLORMAGENTA;
DEA:EMA(DIF,9),COLORGREEN;
MACD:=SMA((DIF-DEA)*10,100,1),COLORSTICK;
{DRAWICON(CROSS(DIF,DEA),DEA,1);
DRAWICON(CROSS(DEA,DIF),DIF,2);
0;}
IF(DIF>=REF(DIF,1),DIF,DRAWNULL),COLORMAGENTA;
IF(DEA>=REF(DEA,1),DEA,DRAWNULL),COLORMAGENTA;
IF(DIF<=REF(DIF,1),DIF,DRAWNULL),COLORGREEN;
IF(DEA<=REF(DEA,1),DEA,DRAWNULL),COLORGREEN;
DIF1:((EMA(CLOSE,14)-EMA(CLOSE,53))),COLORWHITE;
DEA1:EMA(DIF1,5),COLORYELLOW;
MACD1:=(DIF1-DEA1),COLORSTICK;
{DRAWICON(CROSS(DIF1,DEA1),DEA1,11);
DRAWICON(CROSS(DEA1,DIF1),DIF1,12);}
IF(DIF1>=REF(DIF1,1),DIF1,DRAWNULL),COLORYELLOW;
IF(DEA1>=REF(DEA1,1),DEA1,DRAWNULL),COLORYELLOW;
IF(DIF1<=REF(DIF1,1),DIF1,DRAWNULL),COLORGRAY;
IF(DEA1<=REF(DEA1,1),DEA1,DRAWNULL),COLORGRAY;
X_1:=MA(CLOSE,1);
DIF2:EMA(X_1,6)-EMA(X_1,13),COLORWHITE;
DEA2:EMA(DIF2,4),COLORWHITE;
{DRAWICON(CROSS(DIF2,DEA2),DEA2,38);
DRAWICON(CROSS(DEA2,DIF2),DIF2,39);}
MACD2:(DIF2-DEA2)*2,COLORSTICK;
IF(DIF2>=REF(DIF2,1),DIF2,DRAWNULL),COLORRED;
IF(DEA2>=REF(DEA2,1),DEA2,DRAWNULL),COLORRED;
IF(DIF2>=REF(DIF2,1) AND DIF2>0 AND DIF2<MACD2 AND MACD2>=REF(MACD2,1),DIF2,DRAWNULL),COLORYELLOW;
DIF3:=EMA(CLOSE,12)-EMA(CLOSE,25);
DEA3:=EMA(DIF3,5);
MACD3:=(DIF3-DEA3)*2;
MACD120:=REF(MACD3/2,BARSLAST(MACD3=HHV(MACD3,120))),COLORRED,LINETHICK2;
MACD250:=REF(MACD3/2,BARSLAST(MACD3=HHV(MACD3,250))),COLORWHITE,LINETHICK2;
XG:=NOT(REF(MACD120,1)=MACD120);
{STICKLINE(XG,0,MACD3,2,0),COLORYELLOW;
STICKLINE(MACD3>=MACD250,MACD250,MACD3,2,0),COLORMAGENTA;}
大行情:=NOT(REF(MACD120,1)=REF(MACD250,1)) AND MACD120=MACD250;
DRAWTEXT(大行情,0.5,'大牛启动'),COLORFF00FF;
DRAWICON(大行情,0.5,31);
STICKLINE(MACD1>MA(MACD1,5),MACD1,MA(MACD1,5),1,0),COLOR80FFFF;
DRAWICON(CROSS(DIF,DEA),DEA,1);
DRAWICON(CROSS(DIF1,DEA1),DEA1,11);
DRAWICON(CROSS(DIF2,DEA2),DEA2,38);
0;
涨跌停封单:=DYNAINFO(58)*C*100;
DRAWTEXT_FIX(1,0.02,0.06,0,'涨跌封单'),COLORRED;
DRAWNUMBER_FIX(1,0.07,0.06,0,CONST(涨跌停封单)),COLORRED;
封单比:=涨跌停封单/FINANCE(7)*100;
DRAWTEXT_FIX(1,0.02,0.24,0,'封 单 比'),COLORGREEN;
DRAWNUMBER_FIX(1,0.07,0.24,0,CONST(封单比)),COLORGREEN;








回复

举报

QQ|

GMT+8, 2024-11-16 18:06

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