【网络指标】股票之友S理论修改优化集——背离准确率100

背离准确率100

大家可以用原版对照下,看看优化效果之余,再瞄瞄是否有升级空间!
     TIPS: 找背离不是这么简单回事,要动动脑筋,包括背弛!
 
 N:=9;
DIF:=MA(CLOSE,9)-MA(CLOSE,7);
DEA:=MA(DIF,4);
MACD1:=(DIF-DEA)*2;
RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
K:=MA(RSV,4);
D:=MA(K,4);
J:=3*K-2*D;
LC:=REF(CLOSE,1);
RSI1:=MA(MAX(CLOSE-LC,0),9)/MA(ABS(CLOSE-LC),4)*100;
TYP1:=(HIGH+LOW+CLOSE)/3;
CCI1:=(TYP1-MA(TYP1,4))/(0.015*AVEDEV(TYP1,9));


DD:=C=LLV(C,N);{60日最低点}
DDSJ:=BARSLAST(REF(DD,1));{上一低点时间}
DDGJ:=REF(CLOSE,DDSJ+1)>CLOSE;{股价趋势}
KDZB:=REF(J,DDSJ+1);
K底背离:=DDGJ AND KDZB;
GD:=C=HHV(C,N);{60日最高点}
GDSJ:=BARSLAST(REF(GD,1));{上一高点时间}
GDGJ:=REF(CLOSE,GDSJ+1);
KGZB:=REF(J,GDSJ+1)>J;
K顶背离:=GDGJ AND KGZB;
MDZB:=REF(MACD1,DDSJ+1);
M底背离:=DDGJ AND MDZB;
MGZB:=REF(MACD1,GDSJ+1)>MACD1;
M顶背离:=GDGJ AND MGZB;
RDZB:=REF(RSI1,DDSJ+1);
R底背离:=DDGJ AND RDZB;
RGZB:=REF(RSI1,GDSJ+1)>RSI1;
R顶背离:=GDGJ AND RGZB;
TYP:=(HIGH + LOW + CLOSE)/3;
CDZB:=REF(CCI1,DDSJ+1);
C底背离:=DDGJ AND CDZB;
CGZB:=REF(CCI1,GDSJ+1)>CCI1;
C顶背离:=GDGJ AND CGZB;
DRAWTEXT(K顶背离,IF(ISLASTBAR,27.5,25),'←'),LINETHICK2 ;
DRAWTEXT(M顶背离,(ISLASTBAR,24.5,20),'←'),LINETHICK2 ;
DRAWTEXT(R顶背离,(ISLASTBAR,20.5,15),'←'),LINETHICK2 ;
DRAWTEXT(C顶背离,(ISLASTBAR,15.5,10),'←'),LINETHICK2 ;
DRAWTEXT(ISLASTBAR,10.1 ,'CCI '),LINETHICK2,COLORGREEN;
DRAWTEXT(C底背离,IF(ISLASTBAR,12,10),'←'),LINETHICK2,COLORRED;
DRAWTEXT(ISLASTBAR,15,'RSI '),LINETHICK2,COLORRED;
DRAWTEXT(R底背离,IF(ISLASTBAR,8.5,15),'←'),LINETHICK2,COLORRED;
DRAWTEXT(ISLASTBAR,20,'MACD '),LINETHICK2,COLORMAGENTA;
DRAWTEXT(M底背离,IF(ISLASTBAR,4.5,20),'←'),LINETHICK2,COLORRED;
DRAWTEXT(ISLASTBAR,25,'KDJ '),LINETHICK2,COLORRED;
DRAWTEXT(K底背离,IF(ISLASTBAR,1.5,25),'←'),LINETHICK2,COLORRED;
综合顶:=K顶背离+M顶背离+R顶背离+C顶背离;
综合底:=C底背离+R底背离+M底背离+K底背离;
相对顶背离:=综合顶=3;
DRAWICON(综合顶=3 AND C<(REF(C,1)*0.99),40,1);
DRAWICON(综合底=4 AND C<(REF(C,1)*0.99),0,1);




来函数检测结果如下:
该公式没有未来函数

解密、定制、编写股票指标请联系QQ或微信同号:88652583
相关股票指标公式

联系我们  |  股票指标网  |  指标网   |  指标公式  |   加入收藏   |  设为主页

@2005-2023 粤ICP备2023063687号-2 股票指标网别名指标网仅为互联网文章,所有股票指标公式及文章仅供学习研究,并不构成投资建议,请勿以此为依据进行股票交易,由此引起的投资亏损与本站无关。股票指标网均来源互联网收集整理,如不慎侵犯了你的权益,请联系我们告知,我们将做删除处理
QQ:88652583 微信 88652583
sitemap站点地图