通达信自带的CYC成本均线做选股公式

[复制链接]
查看21 | 回复0 | 2022-7-24 07:02:56 | 显示全部楼层 |阅读模式

1.白线黄线与其他两条(紫线,绿线)任意一条线,三线穿过当日K线时选股,四条线同时穿过当日K线时选股
 2.第一条中的选股都满足白线在黄线之上的条件,这样的小多头,会排除下降趋势中的票!

CYC成本均线源码如下:


 JJJ:=IF(DYNAINFO(8)>0.01,0.01*DYNAINFO(10)/DYNAINFO(8),DYNAINFO(3));
 DDD:=(DYNAINFO(5)<0.01 || DYNAINFO(6)<0.01);
 JJJT:=IF(DDD,1,(JJJ<(DYNAINFO(5)+0.01) && JJJ>(DYNAINFO(6)-0.01)));
 CYC1:IF(JJJT,0.01*EMA(AMOUNT,P1)/EMA(VOL,P1),EMA((HIGH+LOW+CLOSE)/3,P1));
 CYC2:IF(JJJT,0.01*EMA(AMOUNT,P2)/EMA(VOL,P2),EMA((HIGH+LOW+CLOSE)/3,P2));
 CYC3:IF(JJJT,0.01*EMA(AMOUNT,P3)/EMA(VOL,P3),EMA((HIGH+LOW+CLOSE)/3,P3));
 CYC∞:IF(JJJT,DMA(AMOUNT/(100*VOL),100*VOL/FINANCE(7)),EMA((HIGH+LOW+CLOSE)/3,120));

选股公式如下:

{穿三线}
 JJJ:=IF(DYNAINFO(8)>0.01,0.01*DYNAINFO(10)/DYNAINFO(8),DYNAINFO(3));
 DDD:=(DYNAINFO(5)<0.01 || DYNAINFO(6)<0.01);
 JJJT:=IF(DDD,1,(JJJ<(DYNAINFO(5)+0.01) && JJJ>(DYNAINFO(6)-0.01)));
 CYC1:=IF(JJJT,0.01*EMA(AMOUNT,5)/EMA(VOL,5),EMA((HIGH+LOW+CLOSE)/3,5));
 CYC2:=IF(JJJT,0.01*EMA(AMOUNT,13)/EMA(VOL,13),EMA((HIGH+LOW+CLOSE)/3,13));
 CYC3:=IF(JJJT,0.01*EMA(AMOUNT,34)/EMA(VOL,34),EMA((HIGH+LOW+CLOSE)/3,34));
 CYC∞:=IF(JJJT,DMA(AMOUNT/(100*VOL),100*VOL/FINANCE(7)),EMA((HIGH+LOW+CLOSE)/3,120));
 A:=CYC1>CYC2 AND CYC1>REF(CYC1,1) AND CYC2>CYC3 AND CYC2>CYC∞;
 B:=MAX(CYC3,CYC∞);
 XG:O<B AND C>CYC1;
 
{穿四线}
 JJJ:=IF(DYNAINFO(8)>0.01,0.01*DYNAINFO(10)/DYNAINFO(8),DYNAINFO(3));
 DDD:=(DYNAINFO(5)<0.01 || DYNAINFO(6)<0.01);
 JJJT:=IF(DDD,1,(JJJ<(DYNAINFO(5)+0.01) && JJJ>(DYNAINFO(6)-0.01)));
 CYC1:=IF(JJJT,0.01*EMA(AMOUNT,5)/EMA(VOL,5),EMA((HIGH+LOW+CLOSE)/3,5));
 CYC2:=IF(JJJT,0.01*EMA(AMOUNT,13)/EMA(VOL,13),EMA((HIGH+LOW+CLOSE)/3,13));
 CYC3:=IF(JJJT,0.01*EMA(AMOUNT,34)/EMA(VOL,34),EMA((HIGH+LOW+CLOSE)/3,34));
 CYC∞:=IF(JJJT,DMA(AMOUNT/(100*VOL),100*VOL/FINANCE(7)),EMA((HIGH+LOW+CLOSE)/3,120));
 A:=CYC1>CYC2 AND CYC1>REF(CYC1,1) AND CYC2>CYC3 AND CYC2>CYC∞;
 B:=MIN(CYC3,CYC∞);
 XG:O<B AND C>CYC1;

84799399.jpg

84799399.jpg

 

回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则