相关简介:通达信金股王主图指标公式源码分享

     通达信指标公式源码概况:

  指标类别:通达信指标公式

  授权方式:免费版

  指标评级:★★★★★

  指标分类:策略

  画线方法:副图

不是原创,有优化,超短线操作,红紫色买进,蓝绿色卖出,希望能帮到大家!

通达信指标公式源码:

   周期:=15;过滤:=8;选股:=-26;抄底:=-40;

   T:0,POINTDOT;

   VAR2:=MA(CLOSE,5);

   VAR3:=MA(CLOSE,10);

   VAR4:=MA(CLOSE,20);

   VAR5:=MA(CLOSE,30);

   VAR6:=(VAR2+VAR3+VAR4+VAR5)/4;

   VAR7:=(VAR6-REF(VAR6,周期))/REF(VAR6,周期)*100;

   VAR8:=(VAR6-REF(VAR6,周期))/REF(VAR6,周期)*100;

   VAR9:=EMA(VAR7,过滤);

   反转:STICKLINE(VAR9>1*REF(VAR9,1),VAR7,0,5,0),COLOREE00EE;

   持股:STICKLINE(VAR7>1*REF(VAR7,1),VAR7,VAR9,5,0),COLORRED;

   持币:STICKLINE(VAR7<1*REF(VAR7,1),VAR7,VAR9,5,1),COLORGREEN;

   洗盘:STICKLINE(VAR7<1*REF(VAR7,1)ANDVAR9>1*REF(VAR9,1),VAR7,VAR9,10,0),

   COLOR00EEFF;

   VAR10:=(CLOSE-MA(CLOSE,58))/MA(CLOSE,58)*100;

   VAR11:=(VAR10>1*REF(VAR10,1)ANDVAR10<选股ANDVAR10>抄底)*1.5;

   VAR12:=VOL/CAPITAL*100;

   VAR13:=LLVBARS(LOW,50);

   VAR14:=SUM(VOL,VAR13);

   VAR15:=HHVBARS(HIGH,50);

   VAR16:=SUM(VOL,VAR15);

   VAR17:=(CLOSE-REF(OPEN,VAR15))/REF(OPEN,VAR15)*100;

   VAR18:=VAR16/CAPITAL*100;

   VAR19:=(CLOSE-REF(OPEN,VAR13))/REF(OPEN,VAR13)*100;

   VAR20:=VAR14/CAPITAL*100;

   VAR21:=MA(CLOSE,3);

   VAR22:=REF(CLOSE,2)*0.865;

   VAR23:=REF(CLOSE,13)*0.772;

   VAR24:=MIN(VAR22,VAR23);

   VAR25:=MA(CLOSE,13);

   抄底王:IF((CLOSE-VAR24)/CLOSE<0.030ANDVAR17<(-35)ANDSUM(VAR12,5)/5<1.800,1

   ,0)*10,COLORWHITE;

   DRAWTEXT(抄底王,抄底王,’成功率90.22%,共发出指示1289次.底追’){,COLORFFAA

   00};

   VAR26:=(CLOSE-REF(CLOSE,1))/REF(CLOSE,1)*100;

   VAR27:=(EMA(CLOSE,12)-EMA(CLOSE,26))*100;

   VAR28:=EMA(VAR27,9);

   VAR29:=2*(VAR27-VAR28);

   DRAWTEXT(VAR27<(-50)ANDVAR26>7ANDVAR27<VAR28,(-10),’底’),COLORWHITE;

   DRAWTEXT(VAR27<(-50)ANDVAR26>7ANDVAR27>=VAR28,5,’追’),COLORWHITE;

   STICKLINE(VAR27<(-50)ANDVAR26>7,0,(-10),5,0),COLORFFFF66;

   N:=10;P:=2;

   MID:ma(CLOSE,N)COLORYELLOW,DOTLINE;

   UP:MID+P*stD(CLOSE,N)COLORLIMAGENTA,DOTLINE,LINETHICK2;

   LO:MID-P*STD(CLOSE,N)COLORLICYAN,DOTLINE,LINETHICK2;

   kdj_K:=”kdJ.K”(9,3,3);

   KDJ_D:=”KDJ.D”(9,3,3);

   KDJ_J:=”KDJ.J”(9,3,3);

   买股票1:=crOSS(KDJ_J,0)OR(CROSS(KDJ_J,KDJ_K)ANDKDJ_D<26);

   买股票2:=CROSS(“rsi.RSI1″(6,2,2),20)ORCROSS(“RSI.RSI1″(6,12,24),”RSI.RSI2″(6,12,24));

   买股票3:=CROSS(“macd.DIF”,”MacD.DEA”)ORCROSS(“MACD.MACD”,0);

   买股票0:=买股票1+买股票2+买股票3;

   买股票:=IF(买股票0>1,买股票0,0);

   DRAWICON(买股票0>1,L*0.97,34);

   VAR1:=CLOSE>REF(CLOSE,1)ANDCLOSE>REF(CLOSE,2);

   VAR2:=REF(VAR1,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VAR3:=REF(VAR2,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VAR4:=REF(VAR3,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VAR5:=REF(VAR4,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VAR6:=REF(VAR5,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VAR7:=REF(VAR6,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VAR8:=REF(VAR7,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VAR9:=REF(VAR8,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VARA:=REF(VAR9,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VARB:=REF(VARA,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VARC:=REF(VARB,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VARD:=CLOSE<REF(CLOSE,1)ANDCLOSE<REF(CLOSE,2);

   VARE:=REF(VARD,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VARF:=REF(VARE,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VAR10:=REF(VARF,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VAR11:=REF(VAR10,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VAR12:=REF(VAR11,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VAR13:=REF(VAR12,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VAR14:=REF(VAR13,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VAR15:=REF(VAR14,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VAR16:=REF(VAR15,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VAR17:=REF(VAR16,1)ANDCLOSE<=REF(CLOSE,1)ANDCLOSE>=REF(CLOSE,2);

   VAR18:=REF(VAR17,1)ANDCLOSE>=REF(CLOSE,1)ANDCLOSE<=REF(CLOSE,2);

   VAR19:=REF(VARDORVAREORVARFORVAR10ORVAR11ORVAR12ORVAR13OR

   VAR14ORVAR15ORVAR16ORVAR17ORVAR18,1)ANDVAR1;

   VAR1A:=REF(VAR1ORVAR2ORVAR3ORVAR4ORVAR5ORVAR6ORVAR7OR

   VAR8ORVAR9ORVARAORVARBORVARC,1)ANDVARD;

   {粉}

   STICKLINE(CLOSE<REF(CLOSE,1),HIGH,LOW,0,0),COLOR00DD00;

   STICKLINE(CLOSE<REF(CLOSE,1),OPEN,CLOSE,3.2,0),COLORFF33FF;

   STICKLINE(CLOSE<REF(CLOSE,1),OPEN,CLOSE,2.7,0),COLORFF55FF;

   STICKLINE(CLOSE<REF(CLOSE,1),OPEN,CLOSE,2.1,0),COLORFF77FF;

   STICKLINE(CLOSE<REF(CLOSE,1),OPEN,CLOSE,1.5,0),COLORFF99FF;

   STICKLINE(CLOSE<REF(CLOSE,1),OPEN,CLOSE,0.9,0),COLORFFBBFF;

   STICKLINE(CLOSE<REF(CLOSE,1),OPEN,CLOSE,0.3,0),COLORFFddfF;

   {金}

   STICKLINE(CLOSE>REF(CLOSE,1),HIGH,LOW,0,0),COLOR000DDD;

   STICKLINE(CLOSE>REF(CLOSE,1),OPEN,CLOSE,3.2,0),COLOR003333;

   STICKLINE(CLOSE>REF(CLOSE,1),OPEN,CLOSE,2.7,0),COLOR005555;

   STICKLINE(CLOSE>REF(CLOSE,1),OPEN,CLOSE,2.1,0),COLOR007777;

   STICKLINE(CLOSE>REF(CLOSE,1),OPEN,CLOSE,1.5,0),COLOR009999;

   STICKLINE(CLOSE>REF(CLOSE,1),OPEN,CLOSE,0.9,0),COLOR00BBBB;

   STICKLINE(CLOSE>REF(CLOSE,1),OPEN,CLOSE,0.3,0),COLOR00DDDD;

   {红}

   STICKLINE(VAR1ORVAR2ORVAR3ORVAR4ORVAR5ORVAR6ORVAR7OR

   VAR8ORVAR9ORVARAORVARBORVARC,CLOSE,REF(CLOSE,1),3.2,0),COLOR000555;

   STICKLINE(VAR1ORVAR2ORVAR3ORVAR4ORVAR5ORVAR6ORVAR7OR

   VAR8ORVAR9ORVARAORVARBORVARC,CLOSE,REF(CLOSE,1),2.7,0),COLOR000777;

   STICKLINE(VAR1ORVAR2ORVAR3ORVAR4ORVAR5ORVAR6ORVAR7OR

   VAR8ORVAR9ORVARAORVARBORVARC,CLOSE,REF(CLOSE,1),2.1,0),COLOR000999;

   STICKLINE(VAR1ORVAR2ORVAR3ORVAR4ORVAR5ORVAR6ORVAR7OR

   VAR8ORVAR9ORVARAORVARBORVARC,CLOSE,REF(CLOSE,1),1.5,0),COLOR000BBB;

   STICKLINE(VAR1ORVAR2ORVAR3ORVAR4ORVAR5ORVAR6ORVAR7OR

   VAR8ORVAR9ORVARAORVARBORVARC,CLOSE,REF(CLOSE,1),0.9,0),COLOR000DDD;

   STICKLINE(VAR1ORVAR2ORVAR3ORVAR4ORVAR5ORVAR6ORVAR7OR

   VAR8ORVAR9ORVARAORVARBORVARC,CLOSE,REF(CLOSE,1),0.3,0),COLOR000FFF;

   {绿}

   STICKLINE(VARDORVAREORVARFORVAR10ORVAR11ORVAR12ORVAR13OR

   VAR14ORVAR15ORVAR16ORVAR17ORVAR18,CLOSE,REF(CLOSE,1),3.2,0),COLOR005500;

   STICKLINE(VARDORVAREORVARFORVAR10ORVAR11ORVAR12ORVAR13OR

   VAR14ORVAR15ORVAR16ORVAR17ORVAR18,CLOSE,REF(CLOSE,1),2.7,0),COLOR007700;

   STICKLINE(VARDORVAREORVARFORVAR10ORVAR11ORVAR12ORVAR13OR

   VAR14ORVAR15ORVAR16ORVAR17ORVAR18,CLOSE,REF(CLOSE,1),2.1,0),COLOR009900;

   STICKLINE(VARDORVAREORVARFORVAR10ORVAR11ORVAR12ORVAR13OR

   VAR14ORVAR15ORVAR16ORVAR17ORVAR18,CLOSE,REF(CLOSE,1),1.5,0),COLOR00BB00;

   STICKLINE(VARDORVAREORVARFORVAR10ORVAR11ORVAR12ORVAR13OR

   VAR14ORVAR15ORVAR16ORVAR17ORVAR18,CLOSE,REF(CLOSE,1),0.9,0),COLOR00DD00;

   STICKLINE(VARDORVAREORVARFORVAR10ORVAR11ORVAR12ORVAR13OR

   VAR14ORVAR15ORVAR16ORVAR17ORVAR18,CLOSE,REF(CLOSE,1),0.3,0),COLOR00FF00;

   {紫}

   STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),3.2,0),COLOR550055;

   STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),2.7,0),COLOR770077;

   STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),2.1,0),COLOR990099;

   STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),1.5,0),COLORBB00BB;

   STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),0.9,0),COLORDD00DD;

   STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),0.3,0),COLORFF00FF;

   {蓝}

   STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),3.2,0),COLORFF3300;

   STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),2.7,0),COLORFF5500;

   STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),2.1,0),COLORFF7700;

   STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),1.5,0),COLORFF9900;

   STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),0.9,0),COLORFFBB00;

   STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),0.3,0),COLORFFDD00;

   DRAWICON(FILTER(VAR19=1,5),L*0.9998,1);

   DRAWICON(FILTER(VAR1A=1,5),H*1.0003,2);

[源码注释]通达信公式动态翻译结果

ZF赋值:(最高价-最低价)/1日前的收盘价*100

输出XG:30日内ZF的低值名次=1

声明:本站所有文章,如无特殊说明或标注,均为本站原创发布。任何个人或组织,在未征得本站同意时,禁止复制、盗用、采集、发布本站内容到任何网站、书籍等各类媒体平台。如若本站内容侵犯了原著者的合法权益,可联系我们进行处理。