通达信公式源码概况:
指标类别:通达信公式
授权方式: 免费版
指标评级: ★★★★★
指标分类: 策略
画线方法: 副图
一、通达信expma选股指标最佳买入必涨
MA30:=EMA(CLOSE,30);强弱:EMA(CLOSE,900);STICKLINE((MA30>强弱),MA30,强弱,1,0),COLOR0000FF;STICKLINE((MA30<强弱),MA30,强弱,1,0),COLOR00FF00;H1:=MAX(DYNAINFO(3),DYNAINFO(5));L1:=MIN(DYNAINFO(3),DYNAINFO(6));P1:=H1-L1;阻力:L1+P1*7/8,COLOR00DD00;支撑:L1+P1*0.5/8,COLOR00DD00;现价:CLOSE,COLORWHITE,LINETHICK1;STICKLINE(CROSS(支撑,现价),支撑,阻力,1,0),COLORYELLOW;DRAWTEXT(LONGCROSS(支撑,现价,2),支撑*1.001,'★B'),COLORYELLOW;{吸}DRAWTEXT(LONGCROSS(现价,阻力,2),现价,'★'),COLORRED;{抛};
VAR1:=LLV(LOW,13);VAR2:=HHV(HIGH,13);VAR3:=SMA((CLOSE-VAR1)/(VAR2-VAR1)*100,5,1);VAR4:=SMA((VAR2-CLOSE)/(VAR2-VAR1)*100,5,1);DRAWBAND(VAR3,RGB(155,50,50),50,RGB(0,100,50));主力:VAR3,COLORRED,LINETHICK2;散户:VAR4,COLORGREEN;VAR5:=SMA(MAX(CLOSE-REF(CLOSE,1),0),5,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),5,1)*100;操作:EMA(VAR5,3),COLORYELLOW;STICKLINE(C,90,90,1,0),COLOR3C3CFF;STICKLINE(C,50,50,1,0),COLORYELLOW;STICKLINE(C,10,10,1,0),COLORCYAN;获利比例:WINNER(CLOSE)*100,NODRAW;换手:SUM(VOL,1)/CAPITAL*100,COLOR666666,NODRAW;⑤日换:SUM(VOL,5)/CAPITAL*100,COLOR999999,NODRAW;
QJJ:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN));XVL:=(IF(CLOSE>OPEN,QJJ*(HIGH-LOW),IF(CLOSE<OPEN,QJJ*(HIGH-OPEN+CLOSE-LOW),VOL/2))+IF(CLOSE>OPEN,0-QJJ*(HIGH-CLOSE+OPEN-LOW),IF(CLOSE<OPEN,0-QJJ*(HIGH-LOW),0-VOL/2)));HSL:=(XVL/20)/1.15;攻击:=((HSL*0.55+(REF(HSL,1)*0.33))+(REF(HSL,2)*0.22));LLJX:=EMA(攻击,3);0,COLORGRAY;B1:SUM(LLJX,1),COLORCYAN;B2:SUM(LLJX,2),COLORGREEN,LINETHICK1;B3:SUM(LLJX,3),COLORGREEN,LINETHICK1;B4:SUM(LLJX,4),COLORGREEN,LINETHICK1;B5:SUM(LLJX,5),COLORGREEN,LINETHICK1;B6:SUM(LLJX,6),COLORGREEN,LINETHICK1;B7:SUM(LLJX,7),COLORGREEN,LINETHICK1;B8:SUM(LLJX,8),COLORGREEN,LINETHICK1;B9:SUM(LLJX,9),COLORGREEN,LINETHICK1;B10:SUM(LLJX,10),COLORB5B500;A1:IF(B1>REF(B1,1),B1,DRAWNULL),COLORRED;A2:IF(B2>REF(B2,1),B2,DRAWNULL),COLORRED;A3:IF(B3>REF(B3,1),B3,DRAWNULL),COLORRED;A4:IF(B4>REF(B4,1),B4,DRAWNULL),COLORRED;A5:IF(B5>REF(B5,1),B5,DRAWNULL),COLORRED;A6:IF(B6>REF(B6,1),B6,DRAWNULL),COLORRED;A7:IF(B7>REF(B7,1),B7,DRAWNULL),COLORRED;A8:IF(B8>REF(B8,1),B8,DRAWNULL),COLORRED;A9:IF(B9>REF(B9,1),B9,DRAWNULL),COLORRED;A10:IF(B10>REF(B10,1),B10,DRAWNULL),COLOR16DCF8,LINETHICK1;
VARTIME:=IF(YEAR>=9999ANDMONTH>=11ANDDAY>=07,0,1);VARDTIME:=IF(YEAR=9999ANDMONTH=11ANDDAY=06,1,0);QW1:=(HIGH+LOW+CLOSE*2)/4*VARTIME;QW3:=EMA(QW1,10)*VARTIME;QW4:=STD(QW1,10)*VARTIME;QW5:=(QW1-QW3)*100/QW4*VARTIME;QW6:=EMA(QW5,5)*VARTIME;RK7:=EMA(QW6,10)*VARTIME;涨:EMA(QW6,10)+100/2-5,LINETHICK1,COLORRED;跌:EMA(涨,4),LINETHICK1,COLORFFFF34;多线:IF(CROSS(涨,跌)AND跌<-10,30,0),LINETHICK1,COLORFF00FF;空线:IF(CROSS(跌,80),70,100),COLOR0099FF,LINETHICK1;买1:EMA(跌,4)*VARTIME,COLORWHITE;买2:EMA(买1,4)*VARTIME,COLORGREEN;买M3:=EMA(买2,4)*VARTIME,COLORYELLOW;买M4:=EMA(买M3,4)*VARTIME,COLORCC9900;-10,POINTDOT,COLOR888888,LINETHICK2;80,POINTDOT,COLOR888888,LINETHICK2;STICKLINE(涨<REF(涨,1)*VARTIME,涨,MA(涨,3),2,0),COLOR00EE00;STICKLINE(涨<REF(涨,1)*VARTIME,涨,MA(涨,3),1,0),COLOR00FF00;STICKLINE(涨>REF(涨,1),涨,EMA(涨,3),3,0),COLOR0099FF;STICKLINE(涨>REF(涨,1),涨,EMA(涨,3),2,0),COLOR00AAFF;STICKLINE(涨>REF(涨,1),涨,EMA(涨,3),1,0),COLOR00BBFF;DRAWICON(多线,30,1),COLORFF00FF;DRAWICON(CROSS(跌,80),70,2),COLORGREEN;DRAWTEXT(CROSS(涨,跌)AND跌<20AND跌>-10,40,'买入'),COLORCCFF99;DRAWTEXT(多线>0,-20,'看涨'),COLOR0000FF;VAR822:=DMA(EMA(CLOSE,12),SUM(VOL,5)/3/CAPITAL)*VARTIME;VAR883:=(CLOSE-VAR822)/VAR822*100*VARTIME;VAR1:=MA(CLOSE,152);VAR2:=MA(CLOSE,194);VAR3:=VAR2+2*STD(CLOSE,170);VAR4:=VAR1+2*STD(CLOSE,170);顶:(CLOSE>VAR3)*13*10,COLORBLUE,LINETHICK2;VAR6:=EMA(HHV(HIGH,500),21);VAR7:=EMA(HHV(HIGH,250),21);VAR8:=EMA(HHV(HIGH,90),21);VAR9:=EMA(LLV(LOW,500),21);VARA:=EMA(LLV(LOW,250),21);VARB:=EMA(LLV(LOW,90),21);VARC:=EMA((VAR9*0.96+VARA*0.96+VARB*0.96+VAR6*0.558+VAR7*0.558+VAR8*0.558)/6,21);VARD:=EMA((VAR9*1.25+VARA*1.23+VARB*1.2+VAR6*0.55+VAR7*0.55+VAR8*0.65)/6,21);VARE:=EMA((VAR9*1.3+VARA*1.3+VARB*1.3+VAR6*0.68+VAR7*0.68+VAR8*0.68)/6,21);VARF:=EMA((VARC*3+VARD*2+VARE)/6*1.738,21);VAR10:=REF(LOW,1);VAR11:=SMA(ABS(LOW-VAR10),3,1)/SMA(MAX(LOW-VAR10,0),3,1)*100;VAR12:=EMA(IF(CLOSE*1.35<=VARF,VAR11*10,VAR11/10),3);VAR13:=LLV(LOW,30);VAR14:=HHV(VAR12,30);VAR15:=IF(MA(CLOSE,58),1,0);VAR16:=EMA(IF(LOW<=VAR13,(VAR12+VAR14*2)/2,0),3)/618*VAR15;VAR17:=IF(VAR16>50,50,VAR16)/3.82*6;VAR18:=HHV(HIGH,30);VAR19:=LLV(LOW,30);NL:=EMA((CLOSE-VAR19)/(VAR18-VAR19)*100,5)/8*10,COLORYELLOW,LINETHICK2;VAR1A:=(EMA(AMOUNT,5)/EMA(VOL,5)/100-EMA(AMOUNT,125)/EMA(VOL,125)/100)/(EMA(AMOUNT,5)/EMA(VOL,5)/100)<-0.4;VAR1B:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;VAR1C:=SMA(VAR1B,3,1);VAR1D:=SMA(VAR1C,3,1);VAR1E:=(-100)*(HHV(HIGH,52)-CLOSE)/(HHV(HIGH,52)-LLV(LOW,52));VAR1F:=COUNT(VAR1A,5)>=1AND(VAR1E<-99.9ORVAR1D<15ANDVAR1C<12);VAR21:=100*WINNER(CLOSE);VAR22:=MA(VAR21,3);VAR25:=SUM(IF(CLOSE>REF(CLOSE,1),1,0),0);VAR26:=SUMBARS(VOL,CAPITAL);VAR27:=IF(CLOSE>LLV(CLOSE,VAR26),1,-1)*IF(VAR25>LLV(VAR25,VAR26),1,-1);VAR28:=COUNT(IF(VAR27=-1,1,0)=1,8)>2;VAR29:=(CLOSE-DMA((3*HIGH+LOW+OPEN+2*CLOSE)/7,VOL/(SUM(AMOUNT,13)/(AMOUNT/VOL/100)/100)))/DMA((3*HIGH+LOW+OPEN+2*CLOSE)/7,VOL/(SUM(AMOUNT,13)/(AMOUNT/VOL/100)/100))*100<-18;VAR2A:=(CLOSE-MIN(REF(CLOSE,5)*0.865,REF(CLOSE,21)*0.772))/CLOSE<0.01;VAR2B:=VAR28ANDVAR29ANDVAR2A;VAR2C:=VOL/CAPITAL>=0.02ANDVOL/CAPITAL<=0.2ANDOPEN=1.105;VAR2D:=VAR2CANDCOUNT(VAR2C,5)=1;VAR2E:=VAR2BORVAR2C;VAR2F:=REF(CLOSE,1);VAR30:=SMA(MAX(CLOSE-VAR2F,0),7,1)/SMA(ABS(CLOSE-VAR2F),7,1)*100;VAR31:=SMA(MAX(CLOSE-VAR2F,0),13,1)/SMA(ABS(CLOSE-VAR2F),13,1)*100;VAR32:=VAR30<20ANDVAR31<25;VAR33:=VAR32;VAR34:=SUM(IF(CLOSE>REF(CLOSE,1),VOL,IF(CLOSE<REF(CLOSE,1),0-VOL,0)),0);VAR35:=IF(CLOSE>LLV(CLOSE,VAR26),1,-1);VAR36:=IF(VAR34>LLV(VAR34,VAR26),1,-1);VAR37:=VAR35*VAR36;VAR38:=IF(VAR37=-1,1,0);VAR3B:=(CLOSE-LLV(LOW,36))/(HHV(HIGH,36)-LLV(LOW,36))*100;VAR3C:=SMA(VAR3B,3,1);VAR3D:=SMA(VAR3C,3,1);VAR3E:=SMA(VAR3D,3,1);VAR3F:=CROSS(VAR3D,VAR3E)ANDVAR3D<20;VAR40:=CROSS(VAR3E,VAR3D)ANDVAR3D>80;VAR41:=5;DRAWTEXT(CROSS(VAR41,NL),30,'★做底'),COLORWHITE;VAR44:=REF(CLOSE,1);VAR45:=SMA(MAX(CLOSE-VAR44,0),6,1)/SMA(ABS(CLOSE-VAR44),6,1)*100;STICKLINE(CROSS(84,VAR45),0,VAR2*15+3,3,1),COLORGREEN;DRAWTEXT(CROSS(84,VAR45),80,'防空警报'),COLORGREEN,;VAR47:=EMA(100*(CLOSE-LLV(LOW,100))/(HHV(HIGH,100)-LLV(LOW,100)),5);VAR48:=(CLOSE-LLV(CLOSE,126))/(HHV(CLOSE,126)-LLV(CLOSE,126))*100;VAR49:=EMA(CLOSE,2)-EMA(CLOSE,150);VAR4A:=EMA(VAR49,100);VAR4B:=2*(VAR49-VAR4A);VAR4C:=POW(VAR4B,3)*0.1+POW(VAR4B,1);VAR4D:=SQRT(SQRT(LOW*HIGH*OPEN*CLOSE));VAR4E:=EMA(VAR4D*0.97,3);VAR4F:=(HIGH+LOW+CLOSE)/3;VAR50:=(VAR4F-MA(VAR4F,14))/(0.015*AVEDEV(VAR4F,14));VAR51:=IF(VAR4B>0.1,VAR4C,0)*5;VAR52:=LLV(HIGH,240);VAR53:=100*(CLOSE-VAR52)/VAR52;VAR54:=AMOUNT/VOL;VAR55:=EMA((WINNER(CLOSE*1.1)-WINNER(CLOSE*0.9))*80,5);VAR56:=INDEXC;VAR57:=MA(VAR56,5);VAR58:=MA(VAR56,20);VAR59:=MA(VAR56,30);VAR5A:=VAR59>VAR57*1.08ANDVAR58>VAR57*1.055;VAR5B:=VAR57>VAR56*1.03ANDVAR58>VAR56*1.13;VAR5C:=VAR5B;VAR5D:=IF(FILTER(VAR55<6,5)=1,1,0);VAR5E:=(VAR5DANDVAR53<-2.5ANDVAR47<5ANDVAR48=0)*60;VAR5F:=VAR55<6ANDVAR5C;VAR60:=IF(FILTER(VAR5F,1)=1,1,0)*80;VAR61:=VAR5FANDVAR5D*80;VAR62:=CROSS(VAR51,2);VAR63:=CROSS(VAR51,4);VAR64:=(CLOSE-MA(CLOSE,6))/MA(CLOSE,6)*100;VAR65:=(CLOSE-MA(CLOSE,12))/MA(CLOSE,12)*100;VAR66:=(CLOSE-MA(CLOSE,24))/MA(CLOSE,24)*100;VAR67:=REF(CLOSE,1);VAR68:=SMA(MAX(CLOSE-VAR67,0),5,1)/SMA(ABS(CLOSE-VAR67),5,1)*100;VAR69:=(HIGH+LOW+CLOSE)/3;VAR6A:=(VAR69-MA(VAR69,14))/(0.015*AVEDEV(VAR69,14));VAR6B:=(VAR64>=-15.8ANDVAR64<=-12.2ANDVAR65<=-20.8ANDVAR66<=-27.5ANDVAR68<=11.7ANDVAR6A<=-145)*100;VAR6C:=VAR48=0;VAR6D:=VAR48=100;VAR6E:=LLV(HIGH,240);VAR6F:=100*(CLOSE-VAR6E)/VAR6E;VAR70:=(CLOSE-LLV(LOW,528))/(HHV(HIGH,528)-LLV(LOW,528))*100;VAR71:=(CLOSE-LLV(CLOSE,530))/(HHV(CLOSE,530)-LLV(CLOSE,530))*100;VAR72:=0;VAR73:=SMA(MAX(CLOSE-REF(CLOSE,1),0),34,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),7,1)*100;VAR74:=SMA(MAX(CLOSE-REF(CLOSE,1),0),13,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),13,1)*100;VAR75:=BARSCOUNT(CLOSE);VAR76:=VAR73<20ANDVAR74<23ANDVAR75>35;VAR77:=VAR76ANDCOUNT(VAR76,1)=1;VAR78:=EMA(CLOSE,21)-EMA(CLOSE,8);VAR79:=EMA(VAR78,5);VAR7A:=TROUGHBARS(3,6,1)<4ANDCROSS(VAR78,VAR79);VAR7B:=IF(TROUGHBARS(3,16,1)=0ANDHIGH>LOW+0.04,4,0);VAR7C:=IF(EMA(CLOSE,5)/EMA(EMA(CLOSE,9),16)<=0.85ANDCLOSE/REF(CLOSE,1)>0.905ANDCLOSE/REF(CLOSE,1)<1.05ANDVOL/CAPITAL*100<5,50,0);VAR7D:=(-100)*(HHV(HIGH,34)-CLOSE)/(HHV(HIGH,34)-LLV(LOW,34))+100;VAR7E:=(-100)*(HHV(HIGH,50)-CLOSE)/(HHV(HIGH,50)-LLV(LOW,50))+100;VAR7F:=(-100)*(HHV(HIGH,70)-CLOSE)/(HHV(HIGH,70)-LLV(LOW,70))+100;VAR80:=((CLOSE-MA(CLOSE,34))/MA(CLOSE,34)*100+10)*5;VAR81:=((CLOSE-MA(CLOSE,50))/MA(CLOSE,50)*100+10)*5;VAR82:=((CLOSE-MA(CLOSE,70))/MA(CLOSE,70)*100+10)*5;VAR83:=(VAR7D+VAR7E+VAR7F+VAR80+VAR81+VAR82)/6;VAR84:=EMA(VAR83,3);VAR85:=ABS(VAR80-VAR82);VAR86:=(VAR83+VAR85)/2;VAR87:=(-1)*(EMA(100*(1-WINNER(CLOSE)),1)-50)+50;VAR88:=VAR87+VAR86;VAR89:=IF(VAR7C>0ANDVAR88<0,200,0);VAR8A:=IF(VAR86<0ANDCLOSE=LLV(CLOSE,5)ANDCLOSE/REF(CLOSE,1)>0.905ANDCLOSE/REF(CLOSE,1)<1.05ANDVOL/CAPITAL*100<5,-50,0);VAR8B:=IF(VAR88<0ANDVAR8A=-50,100,0);VAR8C:=MA(CLOSE,3);VAR8D:=REF(CLOSE,2)*0.865;VAR8E:=REF(CLOSE,13)*0.772;VAR8F:=MIN(VAR8D,VAR8E);VAR90:=100*VOL/CAPITAL;VAR91:=MA(CLOSE,13);VAR92:=IF((CLOSE-VAR8F)/CLOSE<0.03ANDSUM(VAR90,5)/5<1.8,1,0);VAR93:=IF(VAR92>0AND(VAR8A<0ORVAR7C>0),100,0);VAR94:=VAR93;VAR95:=IF(VAR89>0ANDVAR8B>0ANDSUM(VOL/CAPITAL*100,5)/5<1ORVAR92>0ANDREF(CLOSE,1)/REF(CLOSE,2)>0.902OR(VAR89>0ANDVAR8B>0ANDSUM(VOL/CAPITAL*100,5)/5<1ORVAR92>0)AND(VAR8A<0ORVAR7C>0)ANDVAR93<10,50,0);VAR96:=(VAR89>0ANDVAR8B>0ANDSUM(VOL/CAPITAL*100,5)/5<1ORVAR92>0)AND(VAR8A<0ORVAR7C>0);VAR97:=VAR89>0ANDVAR8B>0ANDSUM(VOL/CAPITAL*100,5)/5<1ORVAR92>0ANDREF(CLOSE,1)/REF(CLOSE,2)>0.902;VAR98:=VAR96ORVAR97;VAR99:=SMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(LOW-REF(CLOSE,1))),14,1);VAR9A:=HIGH-REF(HIGH,1);VAR9B:=REF(LOW,1)-LOW;VAR9C:=SMA(IF(VAR9A>0ANDVAR9A>VAR9B,VAR9A,0),12,1);VAR9D:=SMA(IF(VAR9B>0ANDVAR9B>VAR9A,VAR9B,0),12,1);VAR9E:=VAR9C*100/VAR99;VAR9F:=VAR9D*100/VAR99;VARA0:=SMA(ABS(VAR9F-VAR9E)/(VAR9F+VAR9E)*100,12,1);VARA1:=(VARA0+REF(VARA0,5))/2;VARA2:=SUM(HIGH-OPEN,12)/SUM(OPEN-LOW,12)*100;VARA3:=SUM(MAX(0,HIGH-REF(CLOSE,1)),12)/SUM(MAX(0,REF(CLOSE,1)-LOW),12)*100;VARA4:=AMOUNT/VOL/100;VARA5:=(3*HIGH+LOW+OPEN+2*CLOSE)/7;VARA6:=SUM(AMOUNT,5)/VARA4/100;VARA7:=SUM(AMOUNT,13)/VARA4/100;VARA8:=SUM(AMOUNT,34)/VARA4/100;VARA9:=SUM(AMOUNT,209)/VARA4/100;VARAA:=REF(VOL,1)+REF(VOL,2)+REF(VOL,3)+REF(VOL,4);VARAB:=VARAA/CAPITAL;VARAC:=VOL/CAPITAL*VARA5+VARAB*REF(VARA4,1);VARAD:=DMA(VARA5,VOL/VARA6);VARAE:=DMA(VARA5,VOL/VARA7);VARAF:=DMA(VARA5,VOL/VARA8);VARB0:=DMA(VARA5,VOL/CAPITAL);VARB1:=MA(HHV(HIGH,488),18);VARB2:=MA(HHV(HIGH,220),18);VARB3:=MA(HHV(HIGH,98),18);VARB4:=MA(LLV(LOW,488),18);VARB5:=MA(LLV(LOW,220),18);VARB6:=MA(LLV(LOW,98),18);VARB7:=MA((VARB4*0.96+VARB5*0.96+VARB6*0.96+VARB1*0.558+VARB2*0.558+VARB3*0.558)/6,18);VARB8:=MA((VARB4*1.25+VARB5*1.23+VARB6*1.2+VARB1*0.55+VARB2*0.55+VARB3*0.65)/6,18);VARB9:=MA((VARB4*1.3+VARB5*1.3+VARB6*1.3+VARB1*0.68+VARB2*0.68+VARB3*0.68)/6,18);VARBA:=MA((VARB7*3+VARB8*2+VARB9)/6*1.738,18);VARBB:=IF(DATE<=1021231,VARBA,VARBA*DAY);VARBC:=LOW;VARBD:=REF(LOW,1);VARBE:=SMA(ABS(VARBC-VARBD),3,1)/SMA(MAX(VARBC-VARBD,0),3,1)*100;VARBF:=MA(IF(CLOSE*1.35<=VARBB,VARBE*10,VARBE/10),3);VARC0:=LLV(LOW,30);VARC1:=HHV(VARBF,30);VARC2:=IF(LOW<=VARC0,(VARBF+VARC1*2)/2,0);WXBM:(MA(VARC2ANDCLOSE<COST(1),3)AND(CLOSE-VARAE)/VARAE*100<-11)*118,COLORRED,LINETHICK2;STICKLINE(VAR7B>0,0,120,2,0),COLORWHITE;DRAWTEXT(VAR61ORVAR98,70,'★大黑马'),COLORYELLOW;DRAWTEXT(VAR7B>0,60,'★探底'),COLORWHITE;DRAWTEXT(WXBM,100,'BM'),COLORRED,;STICKLINE(VAR61,0,120,3,0),COLORWHITE;STICKLINE(VAR98,0,90,3,0),COLORYELLOW,;X:=C-REF(MA(C,20),11);LGL:=IF(EMA(C,5)/EMA(EMA(C,9),16)<=0.85ANDC/REF(C,1)>0.905ANDC/REF(C,1)<1.05ANDVOL/CAPITAL*100<5,50,0);
评论(0)