找回密码
 立即注册

QQ登录

只需一步,快速开始

广告载入中...
查看: 176|回复: 1

指标编写问答115学习的宝藏

[复制链接]
发表于 2022-1-11 02:25 | 显示全部楼层 |阅读模式

马上注册,享用更多功能,让你轻松玩转本论坛。

您需要 登录 才可以下载或查看,没有账号?立即注册

×
581.问:
      求高手帮编一个连续三天以上收阴的选股公式
    答(了无痕):
      {连阴>=3天}
      XG:COUNT(C<O OR C=O AND C<=REF(C,1),3)=3;
      {阴十字也算阴}



582.问:
      谁有 70万 组合的源码

   答(阿耀):
      我收集的
      上去:ema(c,n1),colorred;
下来:ema(c,n2),colorgreen;
中间:ema(下来,n2),colorwhite,linethick2;
Varf1:=COUNT(CROSS(上去,中间),2)=1;
Varf2:=COUNT(CROSS(下来,中间),2)=1;
ZAI:=FILTER(Varf1 AND Varf2,2);
DRAWTEXT(zai,中间,'¤再上去'),colorwhite;
DRAWTEXT(cross(上去,下来),下来,'★上去↑'),colorred;
DRAWTEXT(cross(下来,上去),下来,'☆下来↓'),colorgreen;
Vv2:=REF(close,1);
Vv3:=SMA((close-Vv2),6,1)/SMA(ABS(close-Vv2),6,1)*100;
DRAWICON(ref(vv3,1)>81 and vv3<80,high,5);
DRAWTEXT(ref(vv3,1)>81 and vv3<80,high*1.39,'做顶↓'),coloryellow;
VF1:=MA(CLOSE,60)-MA(CLOSE,5)/3.2;
DRAWTEXT(IF(CLOSE<VF1 AND VOL/240>MA(VOL,5)/240 AND CLOSE>=REF(CLOSE,1)*1.08 AND CLOSE<MA(CLOSE,13)*1.3,1,0),LOW,'☆'),colorred;
VarA:=(CLOSE-REF(OPEN,29))/REF(OPEN,29)*100;
VarB:=EMA(0.667*REF(VarA,1)+0.333*VarA,5);
DRAWTEXT(IF(VOL>=1.3*MA(VOL,5) AND COUNT(VarA>=VarB and VarA<-17,3) AND REF(LOW,1)=LLV(LOW,120),1,0),LOW,'★注意买入');
Varr1:=SMA(MAX(CLOSE-ref(c,1),0),6,1)/SMA(ABS(CLOSE-ref(c,1)),6,1)*100;
DRAWICON(CROSS(82,Varr1),HIGH*1.05,5);//2
DRAWTEXT(CROSS(82,Varr1),high*1.08,'做顶↓'),coloryellow;
Var1:=(HIGH+LOW+OPEN+2*CLOSE)/5;
Var2:=REF(Var1,1);
Var3:=SMA(MAX(Var1-Var2,0),10,1)/SMA(ABS(Var1-Var2),10,1)*100;
HY3:=IF(COUNT(Var3<20,5)>=1 AND COUNT(Var1=LLV(Var1,10),10)>=1 AND CLOSE>=OPEN*1.038 AND VOL>MA(VOL,5)*1.2,1,0);
DRAWTEXT(hy3,low,'▲注意买入'),colorred;

n1  3/1/100  n2  5/1/100主图    我n1选8   n2选60  



583.问:
    Var3:=100-(100-3*SMA((CLOSE-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))
*100,20,1)+2*SMA(SMA((CLOSE-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))
*100,20,1),15,1));
Var4:=100-(100-3*SMA((OPEN-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))
*100,20,1)+2*SMA(SMA((OPEN-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))
*100,20,1),15,1));

t7:=Var3>REF(Var4,1) AND VOL>REF(VOL,1) AND CLOSE>REF(CLOSE,1);

想要一个选出下面信号的粗选股公式出来:

B7:=DRAWTEXT(t7 and COUNT(t7,30)=1,30,'☆注意 '),COLORYELLOW;
    答(了无痕):
        Var3:=100-(100-3*SMA((CLOSE-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))
*100,20,1)+2*SMA(SMA((CLOSE-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))
*100,20,1),15,1));
Var4:=100-(100-3*SMA((OPEN-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))
*100,20,1)+2*SMA(SMA((OPEN-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))
*100,20,1),15,1));
t7:=Var3>REF(Var4,1) AND VOL>REF(VOL,1) AND CLOSE>REF(CLOSE,1);

XG:t7 and COUNT(t7,30)=1;



584.问:
      如下式中:请帮写:
       1.zq1天数内,涨幅>ref(涨幅,1)时阳线涨幅和。
       2..zq1天数内,涨幅<ref(涨幅,1)时阴线跌幅和.
       b:=ma(c,30);
       jc:=refx(cross(b,ma(b,2)+0.0001) or cross(ma(b,2),b+0.0001) ,1);
       zq1:BARSLAST(jc=1),LINETHICK0;
       zf:=(c-ref(c,1))/ref(c,1)*100;
       涨幅:sum(zf,zq1),Color0000FF,linethick1;
       z1:=涨幅>ref(涨幅,1);
       z2:=涨幅<ref(涨幅,1);
    答(wzlhm ):
       b:=ma(c,30);
       jc:=refx(cross(b,ma(b,2)+0.0001) or cross(ma(b,2),b+0.0001) ,1);
       zq1:BARSLAST(jc=1)+1,LINETHICK0;
       zf:=(c-ref(c,1))/ref(c,1)*100;
       涨幅:sum(zf,zq1),Color0000FF,linethick1;
       z1:=涨幅>ref(涨幅,1);
       z2:=涨幅<ref(涨幅,1);

       {以上是你原来的代码}

       阳线涨幅和:SUM(z1*zf*ISUP,zq1);{1.zq1天数内,涨幅>ref(涨幅,1)时阳线涨幅和。}
       阴线跌幅和:SUM(z2*zf*ISDOWN,zq1);{  2..zq1天数内,涨幅<ref(涨幅,1)时阴线跌幅和.}
                                                



585.问:
      比如说我编一个关于K线的指标,可是如果全在图上标出文字,那图面就太复杂了。能不能      等光标移到那里,他才在光标位置显示"早晨之星"之类的?
     答(雪狐):
      是这样!
      smd:=BACKSET(REF(CLOSE,2)/REF(OPEN,2) < 0.95 AND REF(OPEN,1) < REF(CLOSE,2) AND      ABS(REF(OPEN,1)-REF(CLOSE,1))/REF(CLOSE,1)<0.03 AND CLOSE/OPEN>1.05 AND  CLOSE>REF(CLOSE,2),3);
      DRAWTEXT( smd and SYSPARAM(1)=BARSCOUNT(c) ,l,'早晨之星'),SHIFT1  ,ALIGN1,
      COLORyellow;   


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

本版积分规则

Archiver|手机版|小黑屋|股海明灯官网 ( 京ICP备18020431号 )

GMT+8, 2024-11-23 03:06 , Processed in 0.091687 second(s), Total 11, Slave 10 queries , Gzip On, MemCached On.

Powered by Discuz! X3.5

Copyright © 2001-2024 Tencent Cloud.

快速回复 返回顶部 返回列表