该主图是由“顶底背离”副图转换过来的,使其更直观一些。采用了变色“135战法”均线,同时标示了均线交叉点。
a1:=barslast(ref(cross("macd.diff"(12,26,9),"macd.dea"(12,26,9)),1));
b1:=ref(close,a1+1)>close 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底背离:=filter(b1>0,5);
drawicon(macd底背离,low-0.02,8);
drawtext(macd底背离,low-0.02,' macd底背离'),colormagenta;
a2:=barslast(ref(cross("kdj.k"(9,3,3),"kdj.d"(9,3,3)),1));
b2:=ref(close,a2+1)>close and ref("kdj.k"(9,3,3),a2+1)<"kdj.k"(9,3,3) and cross("kdj.k"(9,3,3),"kdj.d"(9,3,3));
kdj底背离:=filter(b2>0,5);
drawicon(kdj底背离,low-0.06,8);
drawtext(kdj底背离,low-0.06,' kdj底背离'),colorcyan;
a3:=barslast(ref(cross("rsi.rsi1"(6,12,24),"rsi.rsi2"(6,12,24)),1));
b3:=ref(close,a3+1)>close 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底背离:=filter(b3>0,5);
drawicon(rsi底背离,low-0.08,8);
drawtext(rsi底背离,low-0.08,' rsi底背离'),colorred;
c1:=barslast(ref(cross("macd.dea"(12,26,9),"macd.diff"(12,26,9)),1));
d1:=ref(close,c1+1)<close 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顶背离:=filter(d1>0,5);
drawicon(macd顶背离,(high)*(1.04),9);
drawtext(macd顶背离,(high)*(1.04),' macd顶背离'),colorgreen;
c2:=barslast(ref(cross("kdj.d"(9,3,3),"kdj.k"(9,3,3)),1));
d2:=ref(close,c2+1)<close and ref("kdj.k"(9,3,3),c2+1)>"kdj.k"(9,3,3) and cross("kdj.d"(9,3,3),"kdj.k"(9,3,3));
kdj顶背离:=filter(d2>0,5);
drawicon(kdj顶背离,(high)*(1.025),9);
drawtext(kdj顶背离,(high)*(1.025),' kdj顶背离'),colorwhite;
c3:=barslast(ref(cross("rsi.rsi2"(6,12,24),"rsi.rsi1"(6,12,24)),1));
d3:=ref(close,c3+1)<close 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顶背离:=filter(d3>0,5);
drawicon(rsi顶背离,(high)*(1.01),9);
drawtext(rsi顶背离,(high)*(1.01),' rsi顶背离'),coloryellow;
ma13:ema(c,13);
ma34:ema(c,34);
ma55:ema(c,55);
partline(ma13>ref(ma13,1),ma13),colorred,linethick2;
partline(ma13<=ref(ma13,1),ma13),colorblue,linethick2;
partline(ma34>ref(ma34,1),ma34),colormagenta,linethick2;
partline(ma34<ref(ma34,1),ma34),colorgreen,,linethick2;
partline(ma55>ref(ma55,1),ma55),coloryellow,linethick2;
partline(ma55<ref(ma55,1),ma55),colorgray,linethick2;
drawicon(cross(ma13,ma34),ma13,10);
drawicon(cross(ma13,ma55),ma13,10);
drawicon(cross(ma34,ma55),ma34,10);
drawicon(cross(ma34,ma13),ma34,11);
drawicon(cross(ma55,ma13),ma55,11);
drawicon(cross(ma55,ma34),ma55,11);
stickline(close>open,open,low,0.5,0 ),color0000ff;
stickline(close>open,close,high,0.5 ,0 ),color0000ff;
stickline(open>=close,close,low,0.5 ,0 ),color00ff00;
stickline(open>=close,open,high,0.5 ,0 ),color00ff00;
stickline(open>=close ,close ,open,7,0 ),colorff7700;
stickline(open>=close ,close ,open,6,0 ),colorff9900;
stickline(open>=close ,close ,open,5,0 ),colorffbb00;
stickline(open>=close ,close ,open,4,0 ),colorffcc00;
stickline(open>=close ,close ,open,3,0 ),colorffdd00;
stickline(open>=close ,close ,open,2,0 ),colorffee00;
stickline(open>=close ,close ,open,1,0 ),colorffff00;
stickline(close>open,close,open,7,0) ,color000055;
stickline(close>open,close,open,6,0) ,color000066;
stickline(close>open,close,open,5,0) ,color000077;
stickline(close>open,close,open,4,0) ,color000099;
stickline(close>open,close,open,3,0) ,color0000bb;
stickline(close>open,close,open,2,0) ,color0000dd;
stickline(close>open,close,open,1,0) ,color0000ff;
☉ 好公式网发布的指标公式主要用于软件技术面分析,仅供参考,勿用于实际操作,据此操作风险自负!
☉ 解压密码:www.goodgongshi.com 就是好公式网域名,希望大家看清楚,切勿输错。
☉ tnc和tni格式指标公式,仅可以用通达信软件引入使用,例如可以用通达信软件引入使用指标公式;
☉ tne格式指标公式,仅可以用通达信软件公式编辑器5.0版导入,高版本兼容低版本;
☉ fnc格式指标公式,可以用大智慧软件新一代高速行情分析系统股票软件使用,少部分可以用分析家软件引入使用;
☉ alg格式指标公式,仅仅可以用飞狐交易师软件引入使用;exp格式指标公式,仅可以用大智慧经典版软件引入使用;
☉ hxf格式指标公式,仅可以用同花顺软件引入使用。
☉ 如果您发现下载软件链接错误,请联系管理员报告错误。
☉ 好公式网欢迎各位网友帮忙宣传转发本站网址,有您的支持,我们会做得更好!
☉ 本文顶底背离-主图公式 飞狐底背离主图指标 源码仅供学习研究。