优化macd使用方便,能够避免短线的下调线
rsv:=(close-llv(low,9))/(hhv(high,9)-llv(low,9))*100;
k:=sma(rsv,3,1),colorwhite;
d:=sma(k,3,1),coloryellow;
j:=3*k-2*d,colorff00ff;
a:=250;
diff:=(ema(close,12) - ema(close,26));
dea:=ema(diff,9),colorblue,linethick0;
macd:=2*(diff-dea);
mm:=if(macd< 0,macd,0);
jj:=mm> ref(mm,1);
zz:=ref(jj,1)=1;
准备:=(jj and zz)*dea;
stickline(准备=dea,1,-1,2,1),colorffff00;
jh:=hhv(max(k,max(d,j)),a);
dh:=hhv(max(diff,dea),a);
sh:=intpart(jh/dh)/2;
diff50:=sh*diff+50,colorffff00;
dea50:=sh*dea+50,colorblue;
stickline(diff50>dea50,0,1.5*(diff50-dea50),0,0),colorred;
stickline(diff50<dea50,0,1.5*(diff50-dea50),0,0),colorffff00;
红柱:if(1.5*(diff50-dea50)>ref(1.5*(diff50-dea50),1),1.5*(diff50-dea50),0),
stick,;
绿柱:if(1.5*(diff50-dea50)<ref(1.5*(diff50-dea50),1),
1.5*(diff50-dea50),0),stick,colorgreen;
缩头:=if(1.5*(diff50-dea50)>0 and ref(1.5*(diff50-dea50),1)>ref(1.5*(diff50-dea50),2) and 1.5*(diff50-dea50)< ref(1.5*(diff50-dea50),1),1,0);
缩脚:=if(1.5*(diff50-dea50)<0 and ref(1.5*(diff50-dea50),1)< ref(1.5*(diff50-dea50),2) and 1.5*(diff50-dea50)>ref(1.5*(diff50-dea50),1),1,0);
杀多:=if(1.5*(diff50-dea50)<0 and ref(1.5*(diff50-dea50),1)> ref(1.5*(diff50-dea50),2) and 1.5*(diff50-dea50)<ref(1.5*(diff50-dea50),1),1,0);
诱空:=if(1.5*(diff50-dea50)>0 and ref(1.5*(diff50-dea50),1)< ref(1.5*(diff50-dea50),2) and 1.5*(diff50-dea50)>ref(1.5*(diff50-dea50),1),1,0);
阻力:=if(cross(c,ma(c,20)) or cross(c,ma(c,60)),1,0);
drawtext(filter(杀多,3) and 杀多,1.5*(diff50-dea50),'杀多'),colorff00ff;
drawtext(filter(缩头,3) and 缩头,1.5*(diff50-dea50)+0.2,'卖'),colorff00ff;
drawtext(filter(诱空,3) and 诱空,1.5*(diff50-dea50),'?洗盘'),color00ff00;
drawtext(filter(缩脚,3) and 缩脚,1.5*(diff50-dea50)-0.2,'买'),color00ff00;
drawtext(filter(阻力,16) and 1.5*(diff50-dea50)>=0,1.5*(diff50-dea50)+0.01,'¤阻力'),color00ffff;
vra:=ref(close,1);
vrb:=sma(max(close-vra,0),6,1)/sma(abs(close-vra),6,1)*100; //本文来至程序化交易网 cxh99.com//
vrc:=(2*close+high+low)/4;
vr0:=llv(low,34);
vr1:=hhv(high,34);
vr2:=ema((vrc-vr0)/(vr1-vr0)*100,6);
vr3:=ema(0.667*ref(vr2,1)+0.333*vr2,4);
va1:=(ref(high,1)+ref(low,1))/2;
va2:=ma(close,20)+2*std(close,20);
va3:=ref(close,1);
va4:=sma(max(close-va3,0),7,1)/sma(abs(close-va3),7,1)*100;
va5:=cross(79,va4);
va6:=filter(va5,4);
vvd:=ma(close,80)-ma(close,10)/3;
va7:=3*sma((close-llv(low,27))/(hhv(high,27)-llv(low,27))*100,5,1)-2*sma(sma((close-llv(low,27))/(hhv(high,27)-llv(low,27))*100,5,1),3,1);
x1:=cross(va1,va2) or va6;
x2:=cross(84,vrb);
stickline(x1 or x2,1.5*(diff50-dea50)*1.05,1.5*(diff50-dea50)*1.08,3,0);
上一指标公式:老师指标公式详解 同花顺指标
下一指标公式:顾比均线指标公式详解 同花顺均线
☉ 好公式网发布的指标公式主要用于软件技术面分析,仅供参考,勿用于实际操作,据此操作风险自负!
☉ 解压密码:www.goodgongshi.com 就是好公式网域名,希望大家看清楚,切勿输错。
☉ tnc和tni格式指标公式,仅可以用通达信软件引入使用,例如可以用通达信软件引入使用指标公式;
☉ tne格式指标公式,仅可以用通达信软件公式编辑器5.0版导入,高版本兼容低版本;
☉ fnc格式指标公式,可以用大智慧软件新一代高速行情分析系统股票软件使用,少部分可以用分析家软件引入使用;
☉ alg格式指标公式,仅仅可以用飞狐交易师软件引入使用;exp格式指标公式,仅可以用大智慧经典版软件引入使用;
☉ hxf格式指标公式,仅可以用同花顺软件引入使用。
☉ 如果您发现下载软件链接错误,请联系管理员报告错误。
☉ 好公式网欢迎各位网友帮忙宣传转发本站网址,有您的支持,我们会做得更好!
☉ 本文优化MACD指标公式详解 同花顺优化仅供学习研究。