导航:首页 > 源码编译 > 能在图上显示macd背离的源码

能在图上显示macd背离的源码

发布时间:2022-03-31 16:32:07

⑴ 通达信kdj,macd,rsi的底背离副图指标源码黄色显示低吸,柱条变红显示最佳买入,

可以编写kdj,macd,rsi 底背离公式,也可以在低吸德时候显示黄色,买入显示红色,但具体底背离判断方法要说明清楚,只要是底背离就涉及到高低点的位置确认问题,这个高低点确认属于典型的主观分析,还有对比判断的细节,例如macd背离可以是dif背离,可以是dea背离,还可以是macd柱高低背离面积背离。还可以是金叉位置背离,判断的位置条件,判断的内容条件,这些所有条件都说明清楚才能编写公式,而不是说个名字就可以编写公式了。

例如下图有kdj背离,macd背离,rsi背离的主图指标,幅图指标,选股位置提示指标截图。

⑵ 编了个类似macd的指标,如何编写柱状部分的顶底背离公式,比如出现下图走势,在圆圈处出现背离提示

顶底背离:0,COLORYELLOW;
A1:=BARSLAST(ref(cross("macd.diff"(12,26,9),"macd.dea"(12,26,9)),1));
B1:=ref(c,A1+1)>c and ref("macd.diff"(12,26,9),A1+1)<"macd.diff"(12,26,9) and cross
("macd.diff"(12,26,9),"macd.dea"(12,26,9));
MACD底背离:STICKLINE(FILTER(B1>0,5),0,0.75,3,0),COLORGREEN;
DRAWTEXT(FILTER(B1>0,5),0.57,'MACD底背离'),COLORGREEN;
A2:=BARSLAST(ref(cross("kdj.k"(9,9,3),"kdj.d"(9,9,3)),1));
B2:=ref(c,A2+1)>c and ref("kdj.k"(9,9,3),A2+1)<"kdj.k"(9,9,3) and cross
("kdj.k"(9,9,3),"kdj.d"(9,9,3));
KDJ底背离:STICKLINE(FILTER(B2>0,5),0,1,3,0),COLORYELLOW;
DRAWTEXT(FILTER(B2>0,5),0.80,'KDJ底背离'),COLORYELLOW;
A3:=BARSLAST(ref(cross("RSI.RSI1"(6,12,24),"RSI.RSI2"(6,12,24)),1));
B3:=ref(c,A3+1)>c and ref("RSI.RSI1"(6,12,24),A3+1)<"RSI.RSI1"(6,12,24) and cross
("RSI.RSI1"(6,12,24),"RSI.RSI2"(6,12,24));
RSI底背离:STICKLINE(FILTER(B3>0,5),0,0.5,3,0),COLORffcc66;
DRAWTEXT(FILTER(B3>0,5),0.25,'RSI底背离'),COLORffcc66;
2,COLORRED;
C1:=BARSLAST(ref(cross("macd.dea"(12,26,9),"macd.diff"(12,26,9)),1));
D1:=ref(c,C1+1)<c and ref("macd.diff"(12,26,9),C1+1)>"macd.diff"(12,26,9) and cross
("macd.dea"(12,26,9),"macd.diff"(12,26,9));
MACD顶背离:STICKLINE(FILTER(D1>0,5),2,1.25,3,0),COLOR0066FF;
DRAWTEXT(FILTER(D1>0,5),1.47,'MACD顶背离'),COLOR0066FF;
C2:=BARSLAST(ref(cross("kdj.d"(9,9,3),"kdj.k"(9,9,3)),1));
D2:=ref(c,C2+1)<c and ref("kdj.k"(9,9,3),C2+1)>"kdj.k"(9,9,3) and cross
("kdj.d"(9,9,3),"kdj.k"(9,9,3));
KDJ顶背离:STICKLINE(FILTER(D2>0,5),2,1,3,0),COLORRED;
DRAWTEXT(FILTER(D2>0,5),1.2,'KDJ顶背离'),COLORRED;
C3:=BARSLAST(ref(cross("RSI.RSI2"(6,12,24),"RSI.RSI1"(6,12,24)),1));
D3:=ref(c,C3+1)<c and ref("RSI.RSI1"(6,12,24),C3+1)>"RSI.RSI1"(6,12,24) and cross
("RSI.RSI2"(6,12,24),"RSI.RSI1"(6,12,24));
RSI顶背离:STICKLINE(FILTER(D3>0,5),2,1.5,3,0),COLORff00ff

⑶ macd背离通达信系统自动画出

DIFF:EMA(CLOSE,12)-EMA(CLOSE,27),COLORRED;

DEA:EMA(DIFF,9);

MACD:2*(DIFF-DEA), COLORSTICK,LINETHICK2;

低位金叉:=CROSS(DIFF,DEA) AND DIFF<-0.1;

STICKLINE(低位金叉,0,0.08,6,0),COLORYELLOW;

DRAWTEXT(低位金叉,0.16,' 低位金叉'),COLORWHITE;

JCCOUNT:=COUNT(CROSS(DIFF,DEA),BARSLAST(DEA>=0));

二次金叉:=CROSS(DIFF,DEA) AND DEA<0 AND COUNT(JCCOUNT=2,21)=1;

STICKLINE(二次金叉,0,0.06,6,0),COLORFF00FF;

DRAWICON(二次金叉,DEA*0.9,1) ;

DRAWTEXT(二次金叉,0.2,' 二次金叉'),COLORYELLOW;

A1:=BARSLAST(REF(CROSS(DIFF,DEA),1));

底背离:=REF(CLOSE,A1+1)>CLOSE AND DIFF>REF(DIFF,A1+1) AND CROSS(DIFF,DEA);

STICKLINE(底背离,0,0.03,6,0),COLOR00FF00;

底背:DRAWLINE(A1=0,DEA,底背离,DEA,0),COLORRED,LINETHICK4;

DRAWTEXT(底背离,0.12,' 底背离'),COLORFF00FF;

A2:=BARSLAST(REF(CROSS(DEA,DIFF),1));

顶背离:=REF(CLOSE,A2+1)<CLOSE AND REF(DIFF,A2+1)>DIFF AND CROSS(DEA,DIFF);

顶背:DRAWLINE(A2=0,DEA,顶背离,DEA,0),COLORGREEN,LINETHICK4;

DRAWTEXT(低位金叉 AND 二次金叉 AND 底背离,0.25,'三全项'),COLOR0000FF,LINETHICK2;

{二次翻红}

FH1:=REF(MACD,1)<REF(MACD,2) AND REF(MACD,2)<REF(MACD,3) AND REF(MACD,3)<REF(MACD,4);

FH2:=MACD>=0 AND COUNT(MACD>REF(MACD,1),1)=1;

FH3:=FH1 AND FH2 AND EMA(C,13)>REF(EMA(C,13),1);

FH4:=FH1 AND FH2 AND ABS((DIFF-DEA)/C)<0.018;

FH5:=FH1 AND FH2 AND MACD<0.10;

二次翻红:(FH3 OR FH4 OR FH5),COLORRED,NODRAW;

低买:CROSS(DIFF,DEA) AND DIFF<0,COLORFF00FF,NODRAW;

加油:CROSS(DIFF,DEA) AND DIFF>0,COLORYELLOW,NODRAW;

DRAWICON(二次翻红,-0.05,1);

DRAWTEXT(二次翻红,-0.15,'↖翻红'),COLORRED;

DRAWTEXT(CROSS(DIFF,DEA) AND DIFF<0,DEA-0.02,'↖低买'),COLORFF00FF;

DRAWTEXT(CROSS(DIFF,DEA) AND DIFF>0,DEA-0.05,'↖加油'),COLORYELLOW;

XG:二次翻红 OR 低买 OR 加油,NODRAW;


⑷ 通达信有没有什么指标可以判断macd底背离的有的话发几张图看看

通达信系统不自带这样的指标,需要用户根据自己需要的条件编写,例如下图中的macd柱的顶底背离自动画线指标.

⑸ 通达信 macd 背离选股公式 要求有幅图主图画线 选股位置提示

通达信可以编写macd背离选股公式,dif,dea,macd柱的面积,高低点都可以通过参数选择,主图幅图都有画线提示,并且幅图有选股位置提示.效果如下图.

⑹ 求通达信中把MACD顶底背离信号叠加到分时主图上的公式源码

顶背离,你要确定一下是,dif的背离,还是,dea线的背离,还是macd柱子高低的背离.
提示方式是画线提示还是文字提示还是图标提示
例如下图中的是划线提示的

⑺ 求通达信K线和MACD背离时,MACD指标就变色或出现记号的码原。。。。

{这都是答过的问题,网上搜搜};
DIFF:EMA(CLOSE,12)-EMA(CLOSE,26);
DEA:EMA(DIFF,9);
MACD:2*(DIFF-DEA),COLORSTICK,LINETHICK2;
A1:=BARSLAST(REF(CROSS(DIFF,DEA),1));
底背离:=REF(CLOSE,A1+1)>CLOSE AND DIFF>REF(DIFF,A1+1) AND CROSS(DIFF,DEA);
底背:DRAWLINE(A1=0,DEA,底背离,DEA,0),COLORRED,LINETHICK2;
A2:=BARSLAST(REF(CROSS(DEA,DIFF),1));
顶背离:=REF(CLOSE,A2+1)<CLOSE AND REF(DIFF,A2+1)>DIFF AND CROSS(DEA,DIFF);
顶背:DRAWLINE(A2=0,DEA,顶背离,DEA,0),COLORGREEN,LINETHICK2;

⑻ 哪位老师有通达信MACD柱体背离的指标公式分享一个,真心感谢

可以编写macd柱体的顶底背离指标,你是判断macd长短的背离还是判断macd柱面积的背离,再有你所说的颜色变化,用什么颜色怎么变化没明白什么意思有图吗。

下图是macd柱顶底背离画线指标。

阅读全文

与能在图上显示macd背离的源码相关的资料

热点内容
游戏不同的服务器有什么区别 浏览:68
jar线上编译 浏览:115
程序员论坛代码被怼 浏览:996
win7文件夹选项注册表 浏览:786
中央编译局常艳博士照片 浏览:304
濡沫江湖安卓怎么下载 浏览:954
陕西省电信dns服务器云服务器 浏览:826
美辑编译多长时间润色好 浏览:466
服务器心跳地址是什么 浏览:981
编译原理与区别 浏览:978
安利微购app怎么样 浏览:931
ios程序员适合什么键盘 浏览:722
如何把加密pdf转换成excel 浏览:623
文件夹7z如何压缩成rar 浏览:870
android蓝牙低功耗 浏览:277
如何下载好大夫app 浏览:966
linux查看txt 浏览:155
linux硬盘格式化命令 浏览:521
神舞幻想存档放哪个文件夹 浏览:653
怎样把pdf转为图片 浏览:339