最精准指标公式通达信指标公式源码

合集下载

准确率超高通达信指标公式源码

准确率超高通达信指标公式源码

经过实盘操作,准确率很高的指标里有具体的使用说明;VAR1S:=(CLOSE*2+HIGH+LOW)/4;VAR2S:=(EMA(VAR1S,13)-EMA(VAR1S,34))/EMA(VAR1S,34)*100;VAR3S:=EMA(VAR2S,5);主力控盘:=2*(VAR2S-VAR3S)*3.8;SA1:= 主力控盘,COLORWHITE,NODRAW;SA2:=SA1-REF(SA1,1);SA3:=MA(SA1,3),COLORGREEN;SAA3:=MA(SA1,7),COLORCYAN;SAA4:=MA(SA1,13),COLORRED;MM1:=MA(CLOSE,5);Q5:(MM1-REF(MM1,1))/REF(MM1,1)*100,NODRAW,COLORMAGENTA;MTR:=EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-L OW)),14);HD2 :=HIGH-REF(HIGH,1);LD2 :=REF(LOW,1)-LOW;DMP2:=EXPMEMA(IF(HD2>0&&HD2>LD2,HD2,0),14);DMM2:=EXPMEMA(IF(LD2>0&&LD2>HD2,LD2,0),14);PDI2:=DMP2*100/MTR;MDI2:=DMM2*100/MTR;ADX:=EXPMEMA(ABS(MDI2-PDI2)/(MDI2+PDI2)*100,6);ADXR:=EXPMEMA(ADX,6);SAA31:=SAA3-REF(SAA3,1);ADXR12:=MA(ADX,3);ADXR13:=ADX-ADXR12;ADXR14:=ADX-ADXR;ZK2:=ADX<16;ZK3:=(ADXR<16&&ADX<20);ZK31:=ADXR<20&&ADXR>ADX;ZK4:=(ADX<MDI2&&ADXR<MDI2&&ADX<30);ZK41:=(ADX<PDI2&&ADXR<PDI2&&PDI2>MDI2&&ADX<30&&ADX<REF(ADX,1));ZK5:=(ZK2 OR ZK3 OR ZK31);SWQ1:=MAX(ADX,ADXR);AD1:=ADX-REF(ADX,1);Y:=(H+O+L+3*C)/6;X:=EMA(100-(100/(1+SUM(IF(Y>REF(Y,1),Y*VOL,0),13)/SUM(IF(Y<REF(Y,1),Y*VOL,0), 13))),5),COLOR00FFFF,LINETHICK2;AA:=30>X,LINETHICK0;BB:=X>80,LINETHICK0;VAR1:=(C-MA(C,6))/MA(C,6)*100;VAR2:=(C-MA(C,24))/MA(C,24)*100;VAR3:=(C-MA(C,32))/MA(C,32)*100;VAR4:=(VAR1+VAR2+VAR3)/3;VAR5:=EMA(VAR4,5);VAR6:=MA(100*(C-LLV(C,34))/(HHV(H,34)-LLV(L,34)),5)-20;VAR7:=SMA(SMA(100-3*(C-LLV(C,75))/(HHV(H,75)-LLV(L,75))*100,20,1)+SMA(2*(C-LL V(C,75))/(HHV(H,75)-LLV(L,75))*100,20,1),15,1);VAR8:=VAR7<REF(VAR7,1) AND V>REF(V,1) AND C>REF(C,1);K:EMA(VAR5,5)*4;D:EMA(K,5),NODRAW,COLOR38B0DE;J:K*3-D*2,NODRAW,COLORCC66FF;MACD:EMA(EMA(VAR1,5),5)*6,NODRAW,COLORWHITE;{DRAWBAND(J,RGB(238,238,6),K,RGB(256,150,60));}DRAWBAND(K,RGB(238,238,6),D,RGB(256,150,60));按短线卖:IF(EXIST(Q5>2.5,5),-60,DRAWNULL),LINETHICK7,COLORGREEN;按短线卖2:IF(EVERY(Q5<2.5,5)&&MACD>8,-60,DRAWNULL),LINETHICK7,COLORYELLOW;按短线买:IF(EXIST(Q5<-2.5,5),-60,DRAWNULL),LINETHICK7,COLORRED;中线股:IF(SA1>0,-40,DRAWNULL),LINETHICK7,COLORMAGENTA;中线币:IF(SA1<0,-40,DRAWNULL),LINETHICK7,COLORGREEN;盘整币:IF(MDI2>ADXR OR ZK5,-30,DRAWNULL),LINETHICK7,COLORGREEN; DRAWTEXT(EVERY(Q5<1,4)&&Q5>0&&MACD>REF(MACD,1)&&REF(MACD,1)<REF(MAC D,2)&&EVERY(Q5>-0.5,4),MACD*1.04,'P卖'),COLORGREEN;STICKLINE(SA1<REF(SA1,1),0,MACD*1.03,2,1),COLORGREEN;STICKLINE(SA1>REF(SA1,1)&&SA1>0,0,MACD*1.03,2,1),COLORRED;STICKLINE(Q5>5&&SA1>0&&MACD>REF(MACD,1),0,MACD*1.03,2,1),COLORRED; DRAWTEXT(AA&&SA1>REF(SA1,1),MACD*1.1,'吸货'),COLOR0066FF;DRAWTEXT(BB&&SA1<REF(SA1,1),MACD*1.1,'派发'),COLORFFFF00;DRAWTEXT(CROSS(3,Q5)&&EXIST(Q5>4,6),MACD*1.1,'卖4'),COLORGREEN; DRAWTEXT(CROSS(4,Q5)&&EXIST(Q5>5,6),MACD*1.1,'卖5'),COLORGREEN; DRAWTEXT(CROSS(5,Q5)&&EXIST(Q5>6,6),MACD*1.1,'卖6'),COLORGREEN; DRAWTEXT(CROSS(6,Q5)&&EXIST(Q5>7,5),MACD*1.1,'卖7'),COLORGREEN; STICKLINE(MACD>0,0,MACD,1,0),COLORRED;STICKLINE(MACD>0 AND MACD<REF(MACD,1),0,MACD,1,0),COLORFFFF00; STICKLINE(MACD<0,0,MACD,1,0),COLORFF9900;STICKLINE(MACD<0 AND MACD>REF(MACD,1),0,MACD,1,0),COLORFF00FF;MA3:=MA(CLOSE,3);YTSL:=(3*CLOSE+LOW+OPEN+HIGH)/6;辰星线:=(20*YTSL+19*REF(YTSL,1)+18*REF(YTSL,2)+17*REF(YTSL,3)+16*REF(YTSL,4)+1 5*REF(YTSL,5)+14*REF(YTSL,6)+13*REF(YTSL,7)+12*REF(YTSL,8)+11*REF(YTSL,9)+1 0*REF(YTSL,10)+9*REF(YTSL,11)+8*REF(YTSL,12)+7*REF(YTSL,13)+6*REF(YTSL,14)+ 5*REF(YTSL,15)+4*REF(YTSL,16)+3*REF(YTSL,17)+2*REF(YTSL,18)+REF(YTSL,20))/21 1,COLOR0000FF;牵牛线:=MA(CLOSE,26),COLORFF00FF;CX1:=辰星线;QN1:=牵牛线;IF(CX1>REF(CX1,1)&&CX1>QN1,-50,DRAWNULL),LINETHICK7,COLORRED;IF(CX1>REF(CX1,1)&&CX1<QN1,-50,DRAWNULL),LINETHICK7,COLORMAGENTA;IF(CX1<REF(CX1,1)&&CX1<QN1,-50,DRAWNULL),LINETHICK7,COLORGREEN;IF(CX1<REF(CX1,1)&&CX1>QN1,-50,DRAWNULL),LINETHICK7,COLORCYAN; DRAWTEXT(NDAY(SA1,0,2)&&CX1>REF(CX1,1)&&MACD>REF(MACD,1)&&REF(MACD,1) <REF(MACD,2),MACD*1.1,'BBB'),COLORMAGENTA;DA:=(3*CLOSE+OPEN+LOW+HIGH)/6,POINTDOT;X2:=(20*DA+19*REF(DA,1)+18*REF(DA,2)+17*REF(DA,3)+16*REF(DA,4)+15*REF(DA, 5)+14*REF(DA,6)+13*REF(DA,7)+12*REF(DA,8)+11*REF(DA,9)+10*REF(DA,10)+9*RE F(DA,11)+8*REF(DA,12)+7*REF(DA,13)+6*REF(DA,14)+5*REF(DA,15)+4*REF(DA,16)+ 3*REF(DA,17)+2*REF(DA,18)+REF(DA,20))/210,COLORF0F000;X3:=(MA(X2,3)+MA(X2,2))/2,COLORYELLOW,LINETHICK1;DRAWTEXT(SA1>REF(SA1,1)&&SA1>0&&REF(SA1,1)<REF(SA1,2)&&X2>X3,MACD*1.1,'信号1'),COLORMAGENTA;DRAWTEXT(Q5>5&&SA1>0&&MACD>REF(MACD,1)&&REF(MACD,1)<REF(MACD,2)&&X2 >X3,MACD*1.1,'信号2'),COLORRED;DRAWTEXT(MACD>0&&MACD>REF(MACD,1)&&REF(MACD,1)<REF(MACD,2)&&X2>X3,-3,'信号3'),COLORRED;DRAWTEXT(MACD<0 ANDMACD>REF(MACD,1)&&REF(MACD,1)<REF(MACD,2)&&X2>X3,MACD*1.1,'信号4'),COLORWHITE;-60;-50;-40;-30;。

简单明了通达信指标公式源码

简单明了通达信指标公式源码

简单明了通达信指标公式源码
以下是通达信指标公式的源码(部分):
1.移动平均线(MA)
```
MA(CLOSE,N):收盘价的N日简单移动平均线
MA(C,N):C为输入数据,例如指标的参数可以是成交量、MACD柱等;
```
2.指数平滑移动平均线(EMA)
```
EMA(C,N):收盘价的N日指数平滑移动平均线
```
3.相对强弱指标(RSI)
```
RSI(C,N):C为收盘价序列,N为计算周期;
```
4. 随机相对强弱指标(StochRSI)
```
StochRSI(C, N, M1, M2): C为收盘价序列,N为计算RSI的周期,
M1为计算K值的周期,M2为计算D值的周期;
```
5.BOLL指标(布林线)
```
BOLL(CLOSE,N,P):C为收盘价序列,N为计算布林线的周期,P为布林线上下轨的标准差倍数;
```
6.指数平均数指标(EMA)
```
EMA(CLOSE,N):收盘价序列的N日指数平均数;
```
7.指数平滑异同平均线(MACD)
```
MACD(CLOSE,SHORT,LONG,M):C为收盘价序列,SHORT为快速移动平均线的时间周期,LONG为慢速移动平均线的时间周期,M为移动平均线的移动天数;
```
8.能量潮(OBV)
```
OBV(CLOSE,V):C为收盘价序列,V为成交量序列;
```
以上是通达信指标公式的部分源码,还有其他指标的源码未列出。

通达信指标公式源码 阳包阴副图选股指标

通达信指标公式源码 阳包阴副图选股指标

A1:=(REF(C,2)-REF(C,1))/REF(C,2)*100>3;A2:= REF(C,0) > REF(O,1) ;A3:= REF(C,0) > REF(C,1) ;A4:= REF(H,0) > REF(H,1) ;A5:= (C-REF(C,1))/REF(C,1)*100>3;阳包阴1:= A1 AND A2 AND A3 AND A4 AND A5;B1:=(REF(C,2)-REF(C,1))/REF(C,2)*100>4;B2:= REF(C,0) > REF(O,1) ;B3:= REF(C,0) > REF(C,1) ;B4:= REF(H,0) > REF(H,1) ;B5:= (C-REF(C,1))/REF(C,1)*100>5;B6:=V-REF(V,1)<0;B7:=REF(V,2)-REF(V,1)>0;B8:=(H-L)/REF(C,1)*100>5;缩量阳包阴2:= B1 AND B2 AND B3 AND B4 AND B5 AND B6 AND B7 AND B8; C1:=(REF(C,2)-REF(C,1))/REF(C,2)*100>3;{好}C2:= REF(O,0)<REF(L,1);C3:= REF(C,0) > REF(O,1) ;C4:= REF(C,0) > REF(C,1) ;C5:= REF(H,0) > REF(H,1) ;下跳空阳包阴3:= C1 AND C2 AND C3 AND C4 AND C5;D1:=(REF(C,3)-REF(C,2))/REF(C,3)*100>5;D2:= REF(C,1) >= REF(O,1) AND REF(C,1)< REF(O,2);D3:= REF(C,0) > REF(O,0) AND REF(C,0)>REF(C,3);两阳接力包大阴4:(D1 AND D2 AND D3)*100;E1:= REF(C,2) < REF(O,2) AND REF(C,1) <= REF(O,1);E2:=(REF(C,3)-REF(C,1))/ REF(C,3)*100>5;E3:= REF(C,0) > REF(O,0) AND REF(C,0)>REF(C,3);E4:= REF(C,3) > REF(O,3);大阳包二阴5:( E1 AND E2 AND E3 AND E4)*100;阳包阴:(阳包阴1 OR 缩量阳包阴2 OR 下跳空阳包阴3 OR 两阳接力包大阴4 OR 大阳包二阴5)*100,COLOR00FF00,LINETHICK2;DRAWTEXT(阳包阴,80,'★买'),COLOR00FF00;DRAWTEXT(阳包阴,10,'阳包阴'),COLOR00FF00;。

通达信指标公式源码极致贪婪 抄底指标 胜率80+ 副图选股 贴图 不飘移

通达信指标公式源码极致贪婪 抄底指标 胜率80+ 副图选股 贴图 不飘移

X_1:=100;X_2:=DMA(CLOSE,VOL/MA(VOL,4)/4);X_3:=DMA(CLOSE,VOL/MA(VOL,33)/33);X_4:=(CLOSE-X_2)/X_2*100<(-11)/X_1*100;X_5:=(X_2-X_3)/X_3*100<(-22.299999)/X_1*100;X_66:=(REF(OPEN,5)>REF(CLOSE,5) OR REF(OPEN,5)<REF(CLOSE,5)) AND (REF(OPEN,6)>REF(CLOSE,6) OR REF(OPEN,6)<REF(CLOSE,6)) AND (REF(OPEN,7)>REF(CLOSE,7) OR REF(OPEN,7)<REF(CLOSE,7));X_6:=X_4 AND X_5 AND (OPEN>CLOSE OR OPEN<CLOSE) AND(OPEN-REF(CLOSE,1))/REF(CLOSE,1)>(-0.07) AND(REF(CLOSE,1)>REF(OPEN,1) OR REF(CLOSE,1)<REF(OPEN,1)) AND (REF(OPEN,2)>REF(CLOSE,2) OR REF(OPEN,2)<REF(CLOSE,2)) AND (REF(OPEN,3)>REF(CLOSE,3) OR REF(OPEN,3)<REF(CLOSE,3)) AND (REF(OPEN,4)>REF(CLOSE,4) OR REF(OPEN,4)<REF(CLOSE,4)) ANDX_66;{好}X_7:=DMA(CLOSE,VOL/MA(VOL,3)/3);X_8:=DMA(CLOSE,VOL/MA(VOL,33)/33);X_9:=(CLOSE-X_7)/X_7*100<(-5);X_10:=(X_7-X_8)/X_8*100<(-18);X_11:=(INDEXC-LLV(INDEXL,250))/(HHV(INDEXH,250)-LLV(INDEXL,250))*10 0;X_12:=SMA(X_11,30,1);X_13:=SMA(X_12,50,1);X_14:=X_9 AND X_10 AND (OPEN>CLOSE OR OPEN<CLOSE) AND(OPEN-REF(CLOSE,1))/REF(CLOSE,1)>(-0.05) AND(REF(CLOSE,1)>REF(OPEN,1) OR REF(CLOSE,1)<REF(OPEN,1));X_15:=X_14 AND COUNT(X_14,2)=1;X_16:=CLOSE/MA(CLOSE,30)*100<75;X_17:=CLOSE/MA(CLOSE,50)*100<78;X_18:=HIGH>LOW*1.053;X_19:=X_18 AND COUNT(X_18,5)>2;X_20:=X_19 AND (X_16 OR X_17);X_21:=DMA(EMA(CLOSE,5),SUM(VOL,8)/2.8/CAPITAL);X_22:=(CLOSE-X_21)/X_21*100;X_23:=REF(X_22,1)<(-34) AND X_22>REF(X_22,1) ANDREF(X_22,1)<REF(X_22,2) AND X_22-REF(X_22,1)>1.76 OR X_20;X_24:=IF(NAMELIKE(1) OR NAMELIKE(2),0,1);X_25:=DYNAINFO(4)>0;X_26:=X_24 AND X_25;X_27:=X_23 AND (X_6 OR X_15) AND CLOSE>DTPRICE(REF(CLOSE,1),0.1); X_28:=REF(X_23 AND (X_6 OR X_15),1) ANDREF(CLOSE,1)<=DTPRICE(REF(CLOSE,2),0.1) ANDCLOSE>DTPRICE(REF(CLOSE,1),0.1);X_29:=X_27 OR X_28 AND X_26;极致贪婪:X_29 AND COUNT(X_29,3)=1 AND LOW<=LLV(LOW,5) AND CLOSE/LOW<1.02 AND CLOSE/REF(CLOSE,1)<1 AND HIGH/OPEN<1.02 AND COUNT(CLOSE/REF(CLOSE,1)<=0.93,10)>0,COLORCYAN;STICKLINE(极致贪婪,0,50,1,0),COLORCYAN;明日涨停价:ZTPRICE(CLOSE,0.1),NODRAW,COLORWHITE;获利盘:WINNER(CLOSE)*100,NODRAW,COLORLIRED;。

通达信指标公式源码 裸K线主图指标

通达信指标公式源码 裸K线主图指标

VAR1:=CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2);VAR2:=REF(VAR1,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);VAR3:=REF(VAR2,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);VAR4:=REF(VAR3,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);VAR5:=REF(VAR4,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);VAR6:=REF(VAR5,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);VAR7:=REF(VAR6,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);VAR8:=REF(VAR7,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);VAR9:=REF(VAR8,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);VARA:=REF(VAR9,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);VARB:=REF(VARA,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);VARC:=REF(VARB,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARAOR VARB OR VARC,CLOSE,REF(CLOSE,1),3,1),COLORRED;VARD:=CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2);VARE:=REF(VARD,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);VARF:=REF(VARE,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);VAR10:=REF(VARF,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);VAR11:=REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);VAR12:=REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);VAR13:=REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);VAR14:=REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);VAR15:=REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);VAR16:=REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);VAR17:=REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) ANDCLOSE>=REF(CLOSE,2);VAR18:=REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) ANDCLOSE<=REF(CLOSE,2);STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),3,1),COLORFF9900; VAR19:=REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1) AND VAR1; STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),3.0,0),COLOR0088FF; STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),2.0,0),COLOR33AAFF; STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),0.5,0),COLOR66CCFF;VAR1A:=REF(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,1) AND VARD; STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),3.0,0),COLOR008800; STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),2.0,0),COLOR00BB00; STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),0.5,0),COLOR00EE00;。

实战分析思路通达信指标公式源码

实战分析思路通达信指标公式源码

实战分析思路通达信指标公式源码通达信是中国股市中使用较为广泛的一种技术分析软件。

该软件提供了丰富的指标工具,包括均线、MACD、KDJ等等。

对于想要实战分析的投资者,了解这些指标的计算公式是非常重要的。

下面将介绍一些常用指标的计算公式和通达信源码。

1.均线(MA)指标的计算公式如下:MA(n)=(C1+C2+…+Cn)/n其中,MA(n)表示平均线的值,C1、C2、Cn分别表示n个周期内的收盘价。

通达信源码如下:_MA:MA(CLOSE,N);上述代码表示计算周期为N的收盘价的均线。

2.MACD指标的计算公式如下:DIFF = EMA(short) - EMA(long)DEA=EMA(DIFF,M)MACD=(DIFF-DEA)*2其中,EMA表示指数移动平均线,DIFF表示快线与慢线的差值,DEA 为DIFF的M周期指数移动平均,MACD为DIFF与DEA的差值的两倍。

通达信源码如下:_DIFF:EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);_DEA:EMA(_DIFF,M);_MACD:(_DIFF-_DEA)*2;上述代码表示计算DIFF、DEA和MACD三个指标。

3.KDJ指标的计算公式如下:RSV=(CLOSE-LOWEST(CLOSE,N))/(HIGHEST(CLOSE,N)-LOWEST(CLOSE,N))*100K=(1-a)*PREV.K+a*RSVD=(1-a)*PREV.D+a*KJ=3*K-2*D其中,RSV表示未成熟随机值,K、D、J分别表示K、D、J三条曲线的值,N为周期,a为平滑因子。

通达信源码如下:_RSV:(CLOSE-LOWEST(CLOSE,N))/(HIGHEST(CLOSE,N)-LOWEST(CLOSE,N))*100;_k1:(1-a)*REF(_k1,1)+a*_RSV;_d1:(1-a)*REF(_d1,1)+a*_k1;_j1:3*_k1-2*_d1;上述代码表示计算RSV、K、D和J四个指标。

通达信指标公式源码 精准的K线主图公式源码

通达信指标公式源码 精准的K线主图公式源码

BBI:(MA(C,3)+MA(C,6)+MA(C,12)+MA(C,24))/4;MA(C,N1);MA(C,N2);MA(C,N3),LINETHICK2;MA(C,N4),COLORLIRED,LINETHICK2; 买线:=EMA(C,2);卖线:=EMA(SLOPE(C,21)*20+C,42);中:=(MA(CLOSE,30)+MA(C,72))/2,COLOR999999,LINETHICK0;HLY1:=中*1.1,POINTDOT,COLOR999999,LINETHICK0;VAR61:=(CLOSE*2+HIGH+LOW)/4;VAR62:=EMA(VAR61,3);VAR63:=EMA(VAR62,6);L1:=EMA(VAR61,3),LINETHICK0;L2:=EMA(VAR62,4),LINETHICK0;L3:=EMA(VAR63,5),LINETHICK0;{正常上涨}STICKLINE(C>=O,H,L,0,0 ),COLOR0000FF; {红色}STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,3.2,0) ,COLOR000055;STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,2.6,0) ,COLOR000077;STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,1.9,0) ,COLOR000099;STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,1.1,0) ,COLOR0000BB;STICKLINE(CLOSE>=OPEN,CLOSE,OPEN,0.2,0) ,COLOR0000FF; {STICKLINE(CLOSE>OPEN,CLOSE,OPEN,1.2,0) ,COLOR0000EE;STICKLINE(CLOSE>OPEN,CLOSE,OPEN,0.4,0) ,COLOR0000FF;}{正常下跌}STICKLINE(OPEN>=CLOSE,H,L,0,0 ),COLORFFFF00; {天蓝}STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,3.2,0 ),COLORFF5500;STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,2.6,0 ),COLORFF7700;STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,1.9,0 ),COLORFF9900;STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,1.1,0 ),COLORFFBB00;STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,0.2,0 ),COLORFFDD00; {STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,1.2,0 ),COLORFFEE00; STICKLINE(OPEN>=CLOSE ,CLOSE ,OPEN,0.4,0 ),COLORFFFF00;}{整理下跌区}{STICKLINE(L1<L2,H,LOW,0 ,0 ),COLORFFFFFF;{灰色}{STICKLINE(L1<L2,CLOSE ,OPEN,3.0,0 ),COLOR555555;STICKLINE(L1<L2,CLOSE ,OPEN,2.5,0 ),COLOR777777;STICKLINE(L1<L2,CLOSE ,OPEN,1.9,0 ),COLOR999999;STICKLINE(L1<L2,CLOSE ,OPEN,1.2,0 ),COLORBBBBBB;STICKLINE(L1<L2,CLOSE ,OPEN,0.4,0 ),COLORDDDDDD;}{STICKLINE(L1<L2,CLOSE ,OPEN,3,0 ),COLORFFEE00;STICKLINE(L1<L2,CLOSE ,OPEN,2,0 ),COLORFFFF00;}{下跌开始}VAR44:=REF(L1,1)>L1 AND L1>L2;STICKLINE(VAR44,H,LOW,0,0 ),COLORFF0000; {蓝色}{STICKLINE(VAR44,CLOSE,OPEN,3.0,0) ,COLOR550000;STICKLINE(VAR44,CLOSE,OPEN,2.5,0) ,COLOR660000;}STICKLINE(VAR44,CLOSE,OPEN,3.2,0) ,COLOR660000;STICKLINE(VAR44,CLOSE,OPEN,2.6,0) ,COLORAA0000;STICKLINE(VAR44,CLOSE,OPEN,1.9,0) ,COLOREE1100;STICKLINE(VAR44,CLOSE,OPEN,1.1,0) ,COLORFF3300;STICKLINE(VAR44,CLOSE,OPEN,0.2,0) ,COLORFF5500;{顶部钝化区}STICKLINE((CLOSE >= HLY1),H,LOW,0 ,0),COLORFF00FF;{粉色}STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,3.2,0),COLOR770077;STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,2.6,0),COLORAA00AA;STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,1.9,0),COLORDD00DD;STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,1.1,0),COLORFF22FF;STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,0.2,0),COLORFF66FF;{STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,3,0),COLORFFDDFF;STICKLINE((CLOSE >= HLY1),CLOSE ,OPEN,2,0),COLORFFEEFF;}{单边下跌}STICKLINE(买线<卖线,H,LOW,0,0 ),COLOR00FF00; {绿色}STICKLINE(买线<卖线,CLOSE ,OPEN,3.2,0),COLOR004400;STICKLINE(买线<卖线,CLOSE ,OPEN,2.6,0),COLOR005500;STICKLINE(买线<卖线,CLOSE ,OPEN,1.9,0),COLOR007700;STICKLINE(买线<卖线,CLOSE ,OPEN,1.1,0),COLOR009900;STICKLINE(买线<卖线,CLOSE ,OPEN,0.2,0),COLOR00CC00;{STICKLINE(买线<卖线,CLOSE ,OPEN,3,0),COLOR00DD00;STICKLINE(买线<卖线,CLOSE ,OPEN,2,0),COLOR00FF00;}{向上变盘}STICKLINE(CROSS(买线,卖线),H,L,0,0),COLOR0033DD;{橘黄}STICKLINE(CROSS(买线,卖线),C,OPEN,3.2,0),COLOR000077;STICKLINE(CROSS(买线,卖线),C,OPEN,2.6,0),COLOR003399;STICKLINE(CROSS(买线,卖线),C,OPEN,1.9,0),COLOR0033DD;STICKLINE(CROSS(买线,卖线),C,OPEN,1.1,0),COLOR0055FF;STICKLINE(CROSS(买线,卖线),C,OPEN,0.2,0),COLOR0099FF;{向下变盘}STICKLINE(CROSS(卖线,买线),H,L,0,0),COLOR00FFFF;{黄色}STICKLINE(CROSS(卖线,买线),C,OPEN,3.2,0),COLOR008888;STICKLINE(CROSS(卖线,买线),C,OPEN,2.6,0),COLOR00AAAA;STICKLINE(CROSS(卖线,买线),C,OPEN,1.9,0),COLOR00CCCC;STICKLINE(CROSS(卖线,买线),C,OPEN,1.1,0),COLOR00EEEE;STICKLINE(CROSS(卖线,买线),C,OPEN,0.2,0),COLOR44FFFF;N1,N2,N3,N4:分别为:5,10,30,60。

通达信指标公式源码主力进出非常准的指标

通达信指标公式源码主力进出非常准的指标

通达信指标公式源码主力进出非常准的指标通达信指标公式是一个用于计算市场技术指标的软件,这些指标可用
于分析股票、期货或其他金融产品的价格走势。

其中,主力进出指标(Main Force Index)是一种常用的量化技术指标,旨在衡量市场主力资
金的流入和流出情况。

下面是主力进出指标的通达信源码公式:主力买卖指标:=((CLOSE-OPEN)*VOL-(HHV(HIGH,N)-
CLOSE)*SUM(VOL,N)/N+(CLOSE-
LLV(LOW,N))*SUM(VOL,N)/N)/(HHV(HIGH,N)-LLV(LOW,N))/100;
其中,CLOSE表示当日收盘价,OPEN表示当日开盘价,VOL表示当日
成交量,HHV表示最高值函数,HIGH表示当日最高价,LLV表示最低值函数,LOW表示当日最低价,N为计算指标的周期,在这个指标中通常取20。

以上是用于计算主力买卖指标的基本公式,该指标为震荡型指标,主
要分析主力资金的买卖情况。

当主力买卖指标走势上升时,说明主力资金
在加入市场,有可能出现上涨行情;当主力买卖指标走势下降时,说明主
力资金在撤离市场,有可能出现下跌行情。

需要注意的是,主力买卖指标仅仅是市场的一个参考指标,在实际操
作中还需要综合考虑其他技术指标和市场趋势等因素进行综合判断。

以上所述仅为通达信中计算主力买卖指标的源码公式及其基本解释,
该指标的具体使用方式还需根据个人的实际情况进行合理运用。

通达信 指标公式源码大全

通达信 指标公式源码大全

【通达信】魔鬼操盘(主图)-指标公式源码均5:MA(CLOSE,5) COLORYELLOW;均10:MA(CLOSE,10)COLORGREEN;均30: MA(CLOSE,30) COLORMAGENTA ;均60: MA(CLOSE, 60) COLORRED POINTDOT LINETHICK3;均250: MA(CLOSE, 250) COLORBLUE LINETHICK2 ;魔鬼通道上:均30 + 2*STD(CLOSE,60) COLORYELLOW POINTDOT LINETHICK2 ; 魔鬼通道下:均30 - 2*STD(CLOSE,60) COLORYELLOW POINTDOT LINETHICK2; VAR1:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;VAR2:=SMA(VAR1,3,1);VAR3:=SMA(VAR2,3,1);VAR4:=VAR1*1.05;VAR5:=MA(CLOSE,5);VAR6:=(HHV(HIGH,36)-CLOSE)/(HHV(HIGH,36)-LLV(LOW,36))*100;VAR7:=SMA(VAR6,5,1);VAR8:=VOL>REF(VOL,1);VAR9:=MA(VOL/CAPITAL,30)*MA(VOL,60)/10000+MA(CLOSE,30);【通达信】平均价格(主图)-指标公式源码A:=(3*C+H+L+O)/6;XJ:=(A+0.618*REF(A,1)+0.382*REF(A,2)+0.236*REF(A,3)+0.146*REF(A,4))/2 .382;YCZXH:=(MA(HHV(A,2),5)+MA(HHV(A,2),13)+MA(HHV(A,2),21)+MA(HHV(A,2),32 ))/4;YCZXL:=(MA(LLV(A,2),5)+MA(LLV(A,2),13)+MA(LLV(A,2),21)+MA(LLV(A,2),32 ))/4;SMH:EMA(YCZXH,21),COLOR004000;SML:EMA(YCZXL,21),COLOR004000;SMJ:(SML+SMH)/2,COLOR004000;PJ:=(10*A+9*REF(A,1)+8*REF(A,2)+7*REF(A,3)+6*REF(A,4)+5*REF(A,5)+4*RE F(A,6)+3*REF(A,7)+2*REF(A,8)+REF(A,9))/55;A1:=EMA(PJ,3),COLOR004000;A2:=EMA(PJ,5),COLOR004000;A3:=EMA(PJ,7),COLOR004000;A4:=EMA(PJ,9),COLOR004000;A5:=EMA(PJ,11),COLOR004000;LX:=REF(XJ,1);ZD:=(SMA(MAX(XJ-LX,0),5,1)/SMA(ABS(XJ-LX),5,1))*100;KX1:=(CLOSE>=OPEN) AND ZD>=50;KX2:=(CLOSE<OPEN) AND ZD>=50;KX3:=(CLOSE>=OPEN) AND ZD<50;KX4:=(CLOSE<OPEN) AND ZD<50;IF(A5<REF(A5,1),A5,DRAWNULL),COLOR820000,LINETHICK2;IF(A5>REF(A5,1),A5,DRAWNULL),COLOR00005B,LINETHICK2;IF(A4<REF(A4,1),A4,DRAWNULL),COLOR8C0000,LINETHICK1;IF(A4>REF(A4,1),A4,DRAWNULL),COLOR000055,LINETHICK1;IF(A3<REF(A3,1),A3,DRAWNULL),COLOR9B0000,LINETHICK1;IF(A3>REF(A3,1),A3,DRAWNULL),COLOR00006C,LINETHICK1;IF(A2<REF(A2,1),A2,DRAWNULL),COLORBB0000,LINETHICK1;IF(A2>REF(A2,1),A2,DRAWNULL),COLOR00007D,LINETHICK1;IF(A1<REF(A1,1),A1,DRAWNULL),COLORCC0000,LINETHICK1;IF(A1>REF(A1,1),A1,DRAWNULL),COLOR00009B,LINETHICK1;STICKLINE(KX1,C,O,4,1),COLOR4440FF;STICKLINE(KX1,C,H,0.5,1),COLOR4440FF;STICKLINE(KX1,O,L,0.5,1),COLOR4440FF;STICKLINE(KX2,C,O,4,0),COLOR4440FF;STICKLINE(KX2,O,H,0.5,0),COLOR4440FF;STICKLINE(KX2,C,L,0.5,0),COLOR4440FF;STICKLINE(KX3,C,O,4,1),COLORFFFF33;STICKLINE(KX3,C,H,0.5,1),COLORFFFF33;STICKLINE(KX3,O,L,0.5,1),COLORFFFF33;STICKLINE(KX4,C,O,4,0),COLORFFFF33;STICKLINE(KX4,O,H,0.5,0),COLORFFFF33;STICKLINE(KX4,C,L,0.5,0),COLORFFFF33;【通达信】牛劲十足(副图)-指标公式源码VAR1:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN));ZM:=IF(CLOSE>OPEN,VAR1*(HIGH-LOW),IF(CLOSE<OPEN,VAR1*((HIGH-OPEN)+(CL OSE-LOW)),VOL/2)),COLORRED,POINTDOT;ZM1:=IF(CLOSE>OPEN,0-VAR1*((HIGH-CLOSE)+(OPEN-LOW)),IF(CLOSE<OPEN,0-V AR1*(HIGH-LOW),0-VOL/2)),COLOR00FF00,POINTDOT;MMB:=(SUM(ZM,30)+SUM(ZM1,30))/10,COLORYELLOW;SG:=MMB>0 AND REF(MMB,1)<MMB;上攻周期:COUNT(SG,5),LINESTICK,COLORWHITE;JSC:=上攻周期<1;DBQD:=FILTER(COUNT(JSC,5)>3 AND NOT(JSC),10);DRAWICON(DBQD,2,1);DRAWBAND(上攻周期,RGB(255,120,120),3,RGB(0,0,0));DRAWBAND(JSC,RGB(0,0,255),0.5,RGB(0,0,0));STICKLINE(COUNT(上攻周期>3,5)>=3 AND SG,0,上攻周期,1.5,0),COLORRED; XG: COUNT(COUNT(上攻周期>3,5)>=3 AND SG,20)>4;【通达信】魔鬼K线(副图)-指标公式源码VAR1:=REF(OPEN,1);VAR2:=SMA(MAX(OPEN-VAR1,0),6,1)/SMA(ABS(OPEN-VAR1),6,1)*100;VAR3:=REF(CLOSE,1);VAR4:=SMA(MAX(CLOSE-VAR3,0),6,1)/SMA(ABS(CLOSE-VAR3),6,1)*100;VAR5:=REF(HIGH,1);VAR6:=SMA(MAX(HIGH-VAR5,0),6,1)/SMA(ABS(HIGH-VAR5),6,1)*100;VAR7:=REF(LOW,1);VAR8:=SMA(MAX(LOW-VAR7,0),6,1)/SMA(ABS(LOW-VAR7),6,1)*100; STICKLINE(VAR4<VAR2,VAR2,VAR4,5,0),COLORGREEN , ;STICKLINE(VAR4>VAR2,VAR2,VAR4,5,0),COLORRED , ;STICKLINE(VAR4>VAR2 AND VAR6>VAR8 ANDVAR8>VAR4,VAR4,VAR6,0.5,1),COLORRED , ;STICKLINE(VAR4>VAR2 AND VAR6>VAR8 ANDVAR8<VAR4,VAR4,VAR6,0.5,1),COLORRED ,;STICKLINE(VAR4>VAR2 AND VAR6<VAR8 ANDVAR6>VAR4,VAR4,VAR8,0.5,1),COLORRED , ;STICKLINE(VAR4>VAR2 AND VAR6>VAR8 ANDVAR6<VAR2,VAR2,VAR8,0.5,1),COLORRED , ;STICKLINE(VAR4>VAR2 AND VAR6>VAR8 ANDVAR6>VAR2,VAR2,VAR8,0.5,1),COLORRED , ;STICKLINE(VAR4>VAR2 AND VAR6<VAR8 ANDVAR8<VAR2,VAR2,VAR6,0.5,1),COLORRED , ;STICKLINE(VAR4>VAR2 AND VAR6<VAR8 ANDVAR8>VAR2,VAR2,VAR6,0.5,1),COLORRED , ;STICKLINE(VAR4<VAR2 AND VAR6>VAR8 ANDVAR6<VAR4,VAR4,VAR8,0.5,1),COLORGREEN , ;STICKLINE(VAR4<VAR2 AND VAR6<VAR8 ANDVAR8<VAR4,VAR4,VAR6,0.5,1),COLORGREEN , ;STICKLINE(VAR4<VAR2 AND VAR6<VAR8 ANDVAR6>VAR4,VAR4,VAR8,0.5,1),COLORGREEN , ;STICKLINE(VAR4<VAR2 AND VAR6>VAR8 ANDVAR6<VAR4,VAR2,VAR8,0.5,1),COLORGREEN ,;STICKLINE(VAR4<VAR2 AND VAR6>VAR8 ANDVAR6>VAR4,VAR2,VAR8,0.5,1),COLORGREEN , ;STICKLINE(VAR4<VAR2 AND VAR6<VAR8 AND VAR8<VAR2,VAR2,VAR6,0.5,1), COLORGREEN , ;STICKLINE(VAR4<VAR2 AND VAR6<VAR8 ANDVAR8>VAR2,VAR2,VAR6,0.5,1),COLORGREEN , ;【通达信】牛熊分界(立桩量、中线)-指标公式源码AAA:=(3*C+H+L+O)/6;VAR1:=(8*AAA+7*REF(AAA,1)+6*REF(AAA,2)+5*REF(AAA,3 )+4*REF(AAA,4)+3*REF(AAA,5)+2*REF(AAA,6)+REF(AAA,8))/36;VAR2:=(HHV(VA R1,5)+HHV(VAR1,10)+HHV(VAR1,20))/3;VAR3:=(LLV(VAR1,5)+LLV(VAR1,10)+LL V(VAR1,20))/3;VAR4:=(HHV(VAR2,5)+HHV(VAR2,10)+HHV(VAR2,20))/3;VAR5:=( LLV(VAR3,5)+LLV(VAR3,10)+LLV(VAR3,20))/3;VAR6:=(LLV(VAR1,2)+LLV(VAR1,4)+LLV(VAR1,6))/3;DRAWBAND(VAR1,RGB(155,50,50),VAR6,RGB(250,250,0));短线:VAR1,COLORWHITE;中线:VAR6,COLORYELLOW;金叉:短线>中线 AND REF(短线,1)=REF(中线,1),NODRAW;下跌:IF(VAR1=VAR6,VAR6,DRAWNULL),COLORGREEN;TJ1:=VOL=HHV(VOL,10)AND VOL>2*REF(VOL,1)AND CLOSE>VAR1;立桩量:=FILTER(TJ1,5);TJ2:=IF(BARSLAST(立桩量)=1 ANDCLOSE>REF(HIGH,1),1,IF(BARSLAST(立桩量)=2 ANDCLOSE>REF(HIGH,2),1,IF(BARSLAST(立桩量)=3 AND CLOSE>REF(HIGH,3),1,0)));突破:TJ2=1,NODRAW;STICKLINE(CLOSE,REF(HIGH,BARSLAST(立桩量)),REF(HIGH,BARSLAST(立桩量)),1,0),COLORCYAN;STICKLINE(CLOSE,REF(LOW,BARSLAST(立桩量)),REF(LOW,BARSLAST(立桩量)),1,0),COLORYELLOW;STICKLINE(C>=O,C,O,3,0),COLOR000045;STICKLINE(C >=O,C,O,2.5,0),COLOR000065;STICKLINE(C>=O,C,O,2,0),COLOR000085;STICKL INE(C>=O,C,O,1.5,0),COLOR0000A5;STICKLINE(C>=O,C,O,1,0),COLOR0000C5;S TICKLINE(C>=O,C,O,0.5,0),COLOR0000E5;STICKLINE(C>=O,H,L,0,0),COLOR000 0F5;STICKLINE(C<O,C,O,3,0),COLOR353500;STICKLINE(C<O,C,O,2.5,0),COLOR 454500;STICKLINE(C<O,C,O,2,0),COLOR555500;STICKLINE(C<O,C,O,1.5,0),CO LOR656500;STICKLINE(C<O,C,O,1,0),COLOR757500;STICKLINE(C<O,C,O,0.5,0) ,COLOR858500;STICKLINE(C<O,H,L,0,0),COLOR959500;ZRR:=(YEAR-1992)*365+ INTPART((YEAR-1989)/4)+IF(MONTH<=2,DAY+(MONTH-1)*31,DAY+INTPART(13*(M ONTH+1)/5)-7+(MONTH-1)*28+IF(INTPART(YEAR/4)=YEAR/4,1,0)),NODRAW;T:=B ARSLAST(ZRR-REF(ZRR,1)>WEEKDAY-REF(WEEKDAY,1))+1,NODRAW;T1:=REF(T,T)+ T,NODRAW;T2:=REF(T,T1)+T1,NODRAW;T3:=REF(T,T2)+T2,NODRAW;T4:=REF(T,T3 )+T3,NODRAW;T5:=REF(T,T4)+T4,NODRAW;T6:=REF(T,T5)+T5,NODRAW;T7:=REF(T,T6)+T6,NODRAW;T8:=REF(T,T7)+T7,NODRAW;周10:(REF(CLOSE,T)+REF(CLOSE,T1)+REF(CLOSE,T2)+REF(CLOSE,T3)+REF(CLOSE, T4)+REF(CLOSE,T5)+REF(CLOSE,T6)+REF(CLOSE,T7)+REF(CLOSE,T8)+CLOSE)/10 ,LINETHICK2;【通达信】牛准反弹(快线、慢线)-指标公式源码N:=9;M1:=3;M2:=3;P:=9;快线:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;慢线:=SMA(快线,M1,1);ELI空:=SMA(慢线,M2,1);ELI牛股:=IF(BARSLAST(CROSS(慢线,ELI空))<P AND CROSS(慢线,ELI空) AND 慢线<20,90,0);LC:=REF(CLOSE,1);RSI:=SMA(MAX(CLOSE-LC,0),4.1,1)/SMA(ABS(CLOSE-LC),4.1,1)*100;牛准反弹:=CROSS(RSI,11)*80;XG:牛准反弹 OR ELI牛股;【通达信】启动提示(平台线、启动线)-指标公式源码启动线:SUM(EMA((C+L)/2,2),5)/10.158,COLORRED;平衡线:LLV(SUM( EMA((C+L)/2,2),5)/10.158,4),COLORFF00FF;平台线:LLV(SUM( EMA((C+L)/2,2),5)/10.158,10),COLORFFFFFF;强弱线:EMA(启动线,21),COLORYELLOW;STICKLINE(平台线<启动线,启动线,平台线,0.1,0),COLORFFCCAA; STICKLINE(平衡线<启动线,启动线,平衡线,0.1,0),COLORRED;VAR1:=2*MA(LLV((C+L)/2,8)*1.1,13)-EMA((C+L)/2,3)-((C+L)/2)*0.1;VAR2:=IF((EMA((C+L)/2,3)-VAR1)*5>0,POW((EMA((C+L)/2,3)-VAR1)*5,2)/10, -1*POW((EMA((C+L)/2,3)-VAR1)*5,2)/10);VAR3:=IF(VAR2>0,VAR2-0,0);STICKLINE(VAR3>0 AND REF(VAR3,1)=0 AND (C+L)/2>MA((C+L)/2,8),强弱线,强弱线+0.2,4,0),COLORFFAACC;DRAWTEXT(VAR3>0 AND REF(VAR3,1)=0 AND (C+L)/2>MA((C+L)/2,8),强弱线+0.35,'注意控制'),LINETHICK3,COLORFFAACC;【通达信】平台启动(主图)-指标公式源码圣:=(HHV(HIGH,21)-CLOSE)/(HHV(HIGH,21)-LLV(LOW,21))*100-10;灵:=(CLOSE-LLV(LOW,21))/(HHV(HIGH,21)-LLV(LOW,21))*100;石:=SMA(灵,13,8);仙:=CEILING(SMA(石,13,8));编著:=SMA(圣,21,8);AABB:=IF(L,CONST(L),DRAWNULL);平台启动:STICKLINE(仙-编著>75,AABB,AABB*0.99,15,1),COLOR0000FF; VARZT:=BARSLAST(平台启动);DRAWTEXT(VARZT=1,0.99*(AABB+AABB*0.98)/2,'平台启动'),COLORYELLOW;【通达信】牛熊线分水岭(中线强弱拐点)-指标公式源码JJ:=(CLOSE+HIGH+LOW)/3;A:=EMA(JJ,10);B:=REF(A,1);M1:=EMA(CLOSE,3);M2:EMA(CLOSE,8);分水岭:SMA(M2,2.5,1.5),LINETHICK2,COLORRED;牛线:3*M2-2*分水岭,LINETHICK2,COLORFF00FF ;熊线:4*分水岭-3*M2,LINETHICK2,COLORGREEN;IF (牛线<=熊线,牛线,熊线),COLORGREEN,LINETHICK2;IF (分水岭<=熊线,分水岭,熊线),COLORGREEN,LINETHICK2;IF(牛线>REF(熊线,1),熊线,DRAWNULL),COLORFF2200,LINETHICK2;M3:EMA(M2,13);M4:EMA(M2,55);VAR1:=EMA(M3,55);M5:EMA(M4,81), COLORRED,LINETHICK1;股道:=(1-C/SMA(C,13,1))*100;基础:=EMA(C,43);中线强弱拐点:EMA(股道*C/100+基础,3),COLORGRAY,LINETHICK1;。

通达信指标公式源码 自己用的KD副图指标

通达信指标公式源码 自己用的KD副图指标

RSV:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;K:SMA(RSV,M1,1);D:SMA(K,M2,1);金:BARSLAST(CROSS(K,D))NODRAW;死:BARSLAST(CROSS(D,K))NODRAW; DRAWICON(CROSS(K,D),D,1); {K上穿D做记号};DRAWICON(CROSS(D,K),K,2); {D下穿K做记号};A80:80,DOTLINE,COLORMAGENTA,LINETHICK1;VAR1:=C-REF(C,1);VAR2:=100*EMA(EMA(VAR1,6),6)/EMA(EMA(ABS(VAR1),6),6);MA5:=EMA(C,5);{好}MA13:=EMA(C,13);UP:=DRAWLINE(L=LLV(L,BARSLAST(CROSS(MA13,MA5))+1),LLV(L,BARSLAS T(CROSS(MA13,MA5))+1),H=HHV(H,BARSLAST(CROSS(MA5,MA13))+1),HHV(H,BARSL AST(CROSS(MA5,MA13))+1),0),COLOR0000FF;DOWN:=DRAWLINE(H=HHV(H,BARSLAST(CROSS(MA5,MA13))+1),HHV(H,BA RSLAST(CROSS(MA5,MA13))+1),L=LLV(L,BARSLAST(CROSS(MA13,MA5))+1),LLV(L,BARSLAS T(CROSS(MA13,MA5))+1),0),COLOR00FF00;BT:(LLV(VAR2,2)=LLV(VAR2,7) AND COUNT(VAR2<0,2) ANDCROSS(VAR2,MA(VAR2,2))) ANDREF(DOWN,1)<REF(DOWN,2) AND UP>REF(DOWN,1);STICKLINE(UP,0,3,2,0),COLOR0000FF;STICKLINE(DOWN,0,3,2,0),COLOR00FF00;STICKLINE(BT,0,30,2,0),COLOR000088;STICKLINE(BT,0,30,1,0),COLOR0000CC;STICKLINE(BT,0,30,0.22,0),COLOR0000FF;DRAWTEXT(BT,30,'短牛'),COLOR0000FF;TJ1:=REF(DOWN,1)<REF(DOWN,2) AND UP>REF(DOWN,1) ANDC<HHV(H,21)*0.82;STICKLINE(TJ1,0,20,3,0),COLOR880088;STICKLINE(TJ1,0,20,1.5,0),COLORAA00AA;STICKLINE(TJ1,0,20,0.8,0),COLORCC00CC;STICKLINE(TJ1,0,20,0.2,0),COLORFF00FF;DRAWTEXT(TJ1,20,'中牛'),COLORFF00FF;HR:=HHV(HIGH,55);HRY:=LLV(LOW,55);HRY11:=HR*HRY;HRY33:=SQRT(HRY11);TJ2:=REF(DOWN,1)<REF(DOWN,2) AND UP>REF(DOWN,1) AND C<HRY33; STICKLINE(TJ2,0,10,3,0),COLOR008888;STICKLINE(TJ2,0,10,2,0),COLOR00AAAA;STICKLINE(TJ2,0,10,1,0),COLOR00CCCC;STICKLINE(TJ2,0,10,0.2,0),COLOR00FFFF;DRAWTEXT(TJ2,10,'大牛'),COLOR00FFFF;ST:=REF(UP,1)>REF(UP,2) AND DOWN<REF(UP,1);STICKLINE(ST,100,90,2,0),COLOR008800;STICKLINE(ST,100,90,2,0),COLOR00AA00;STICKLINE(ST,100,90,1,0),COLOR00CC00;STICKLINE(ST,100,90,0.2,0),COLOR00FF00;DRAWTEXT(ST,90,'卖'),COLORFFFFFF;DRAWICON(BT AND TJ1 AND TJ2,5,25);上升:IF(K>REF(K,1),K,DRAWNULL),LINETHICK1,COLORRED;。

通达信指标公式源码绝密买卖点指标

通达信指标公式源码绝密买卖点指标

{买卖密码}JRH:=HHV(C,2);JRL:=LLV(C,2);MA3:=MA(CLOSE,3);YTSL:=(3*CLOSE+LOW+OPEN+HIGH)/6;R1:=(CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2));R2:=(REF(R1,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); R3:=(REF(R2,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); R4:=(REF(R3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); R5:=(REF(R4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); R6:=(REF(R5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); R7:=(REF(R6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); R8:=(REF(R7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); R9:=(REF(R8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); RA:=(REF(R9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); RB:=(REF(RA,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); RC:=(REF(RB,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); RD:=(CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2));RE:=(REF(RD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); RF:=(REF(RE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); R10:=(REF(RF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); R11:=(REF(R10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); R12:=(REF(R11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); R13:=(REF(R12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2)); R14:=(REF(R13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2)); R15:=(REF(R14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));R16:=(REF(R15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));R17:=(REF(R16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));R18:=(REF(R17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));R19:=REF(RD OR RE OR RF OR R10 OR R11 OR R12 OR R13 OR R14 OR R15 OR R16 OR R17 OR R18,1) AND R1;R1A:=((REF(R1 OR R2 OR R3 OR R4 OR R5 OR R6 OR R7 OR R8 OR R9 OR RA OR RB OR RC,1)) AND RD);VAR3:=IF(C<200 ,MA(COST(80),3),2500),NODRAW;VAR4:=(((HIGH + LOW) + CLOSE) / 3);VAR55:=EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),2330);VAR66:=(VAR55 + ((VAR55 * 6) / 100));短买春:=R19,NODRAW,COLOR00DD00;秋离场:=R1A,NODRAW,COLOR2288EE;红持股:=R1 OR R2 OR R3 OR R4 OR R5 OR R6 OR R7 OR R8 OR R9 OR RA OR RB OR RC,NODRAW,COLOR0000FF;急速超跌关注:=(CLOSE-MA(CLOSE,34))/MA(CLOSE,34)*100<-14,COLORBBBBBB,NODRAW;Q1:=CONST(IF(短买春,0,IF(秋离场,150,IF(红持股,150,IF(急速超跌关注,150,100))))),NODRAW; Q2:=CONST(IF(短买春,80,IF(秋离场,100,IF(红持股,0,IF(急速超跌关注,150,100))))),NODRAW;Q3:=CONST(IF(短买春,0,IF(秋离场,20,IF(红持股,70,IF(急速超跌关注,150,100))))),NODRAW;DD1:=EMA((O+H+L)/3,4)COLORWHITE,NODRAW;DD2:=EMA(C+(H-L)*0.618,3)COLORYELLOW,NODRAW;密码1:DD2+(DD2-DD1)*0.618,NODRAW,COLORWHITE;{明卖}密码2:EMA((O+H+L)/3,4)+((H+L)/2-REF((O+H+L)/3,3))/4,NODRAW;{明买}密码3:=MA(REF(密码1,1),1)*1,COLORLIMAGENTA,NODRAW;{今卖}密码4:=REF(密码2,1),COLORLIMAGENTA,NODRAW;{今买}密码5:=MA(REF(DD2,1),1)*1,COLORLIMAGENTA,NODRAW;{今卖}密码6:=REF(DD1,1),COLORLIMAGENTA,NODRAW;{今买}{黄金买点:=EMA((O+H+L)/3,4)COLORWHITE,NODRAW;黄金卖点:=EMA(C+(H-L)*0.618,3)COLORYELLOW,NODRAW;预测明日卖点:黄金卖点+(黄金卖点-黄金买点)*0.618,NODRAW,COLORWHITE;预测明日买点:EMA((O+H+L)/3,4)+((H+L)/2-REF((O+H+L)/3,3))/4,NODRAW;今卖:MA(REF(预测明日卖点,1),1)*1,COLORLIMAGENTA,NODRAW;今买:REF(预测明日买点,1),COLORLIMAGENTA,NODRAW;}换:IF(CAPITAL>0,V/CAPITAL*100,V),NODRAW;收:=FINANCE(33),NODRAW;流:FINANCE(7)/100000000,NODRAW;TT:=IF(ISLASTBAR,240/FROMOPEN,1);NN:=120;HH:=HHV(V*TT,NN);LL:=LLV(V,NN);最高:=CONST(HH);最低:=CONST(LL);RCC:=最高*0.9-(最高-最低)*0.5;RHL:=RCC;HLMAX:=最高;HLMIN:=最低;HLMN1:=(HLMAX+HLMIN)/2;HLMN2:=HLMAX-HLMIN;HLMN3:=(100-0)/2*1.3;HLMN4:=(100-0)/1*1.3;P:=最高/120;{顶底摸块}神:=2*SMA(V*((C+L)/2+(H+C)/2+L)/3,2,1)/SMA(V,2,1)-(3*HHV(SMA(V*((C+L)/2+(H+C)/2+L)/3,2,1)/ SMA(V,2,1),2)-2*SMA(V*((C+L)/2+(H+C)/2+L)/3,2,1)/SMA(V,2,1));奇:=(2*神+EMA((2*(C+L)/2+(H+C)/2+L+O)/5,2)+2*((EMA((C*2+H+L+O)/5,5)+MA((C*2+H+L+O)/5,13)+MA((C *2+H+L+O)/5,21))/3)+((EMA((C*2+H+L+O)/5,13)+MA((C*2+H+L+O)/5,21)+MA((C*2+H+L+O)/5,34))/3)+((EMA((C*2+H+L+O)/5,2 1)+MA((C*2+H+L+O)/5,34)+MA((C*2+H+L+O)/5,55))/3))/7;分清:=(FORCAST(HHV((C+L)/2,1),21)+(EMA(((C+L)/2+L+(H+C)/2)/3,55)-(C-EMA(((C+L)/2+L+(H+C)/2)/3, 55))))/2;放心买入:=(((C+L)/2+(H+C)/2+L)/3+(3*(C+H+L+(O+C+L)/3)/4-2*(C+L)/2))/2;强:=(EMA((分清+3*((EMA(放心买入,5)*5+分清)/6+((EMA(奇,5)+EMA(奇,8)+EMA(奇,13))/3))/2)/4,3)/3),POINTDOT,COLOR00FFFF;验证:=((((C+L)/2-LLV(L,24))/(HHV((H+C)/2,24)-LLV(L,24))*1.1*(C+L)/2));续持验证:=EMA((2*(5*((EMA((2*C+L)/3,2)-EMA((2*C+H)/3,5))-EMA((EMA((2*C+L)/3,2)-EMA((2*C+H)/3,5)),21)))+(((C*2+H)/3+(C*2+H)/3)/2)+EMA(验证,2))/4,2),COLOR555555;AR:=(2*(C+L)/2+REF((C+L)/2,1))/3;BR:=(7*(C+L)/2+6*REF((C+L)/2,1)+5*REF((C+L)/2,2)+4*REF((C+L)/2,3)+3*REF((C+L)/2,4)+2*REF((C+L)/2,5)+REF((C+L)/2,6))/28;VARA2:=LLV(MA(LOW,3),3);VARA3:=HHV(MA(HIGH,3),3);比:=TT;昨V:=REF(V,1);T:=IF(ISLASTBAR,IF(FROMOPEN>60,IF(FROMOPEN-INTPART(FROMOPEN/60)*60=0,1,60/(FROMOPEN-INTPART(FROMOPEN/60)*60)),60/FROMOPEN),1);WJ:=(H+L+C)/3;V1:=IF(H=L,1,H-MAX(O,C));V2:=IF(H=L,1,MAX(C,O)-WJ);V3:=IF(H=L,1,MIN(O,C)-L);V4:=IF(H=L,1,WJ-MIN(C,O));V5:=VOL/IF(H=L,4,H-L);V6:=(V1*V5);V7:=(V2*V5);V8:=(V3*V5);V9:=(V4*V5);买盘1:=DYNAINFO(23)*比;卖盘1:=DYNAINFO(22)*比;买盘2:=IF(ISLASTBAR AND C>300,(V9+V8)*TT,(V9+V8));卖盘2:=IF(ISLASTBAR AND C>300,(V6+V7)*TT,(V6+V7));买盘:=IF(ISLASTBAR AND PERIOD=5 AND C<300,买盘1,买盘2);卖盘:=IF(ISLASTBAR AND PERIOD=5 AND C<300,卖盘1,卖盘2);DRAWBAND(最高,RGB(Q1,Q2,Q3),0,DRAWNULL);买卖差:=买盘-卖盘;STICKLINE(C>=O,0,买盘+卖盘,2.8,1),COLORRED;STICKLINE(C<O,0,买盘+卖盘,2.8,1),COLORFFFF00;STICKLINE(买卖差>=0,0,买盘,2.5,0),COLORRED;STICKLINE(买卖差>=0 AND C>=MA(C,30),0,买盘,3.0,0),COLORRED;STICKLINE(买卖差>=0,0,卖盘,1.1,0),COLOR998800;STICKLINE(买卖差>=0 AND C>=MA(C,30),0,卖盘,1.5,0),COLORDDCC00;STICKLINE(买卖差<0,0,买盘,2.5,0),COLORRED;STICKLINE(买卖差<0 AND C>=MA(C,30),0,买盘,3.0,0),COLORRED;STICKLINE(买卖差<0,0,卖盘,1.1,0),COLOR998800;STICKLINE(买卖差<0 AND C>=MA(C,30),0,卖盘,1.5,0),COLORDDCC00;A1:=REF(CLOSE,1);B1:=(买盘+卖盘)<MA(V,60)/3 ;{B1:=V<MA(V,60)/3 ;}B2:=MA(V,5)/2>V AND V>B1;STICKLINE(B1,0,卖盘,2,0),COLORYELLOW;((80-HLMN3)*HLMN2/HLMN4+HLMN1),COLORCCCCCC,LINETHICK1,DOTLINE;((50-HLMN3)*HLMN2/HLMN4+HLMN1),COLORCCCCCC,LINETHICK1,DOTLINE;((20-HLMN3)*HLMN2/HLMN4+HLMN1),COLORCCCCCC,LINETHICK1,DOTLINE;KA:=(EMA((CLOSE-VARA2)/(VARA3-VARA2)*100,4)-50)*0.5+50;DB:=EMA(0.667*REF(KA,1)+0.333*KA,2);JJ:=3*KA-2*DB;((KA-HLMN3)*HLMN2/HLMN4+HLMN1),COLORFFF111,LINETHICK1;((DB-HLMN3)*HLMN2/HLMN4+HLMN1),COLOR00FF00,LINETHICK1;((JJ-HLMN3)*HLMN2/HLMN4+HLMN1),COLORFF00FF,LINETHICK1;IF(续持验证<强,-5*P,DRAWNULL),CIRCLEDOT,COLORYELLOW,LINETHICK1;IF(续持验证>=强,-5*P,DRAWNULL),CIRCLEDOT,COLORRED,LINETHICK1;IF(续持验证>= REF(续持验证,1),-15*P,DRAWNULL),CIRCLEDOT,COLORRED,LINETHICK1; IF(续持验证< REF(续持验证,1),-15*P,DRAWNULL),CIRCLEDOT,COLORYELLOW,LINETHICK1; STICKLINE(1,HLMAX,HLMAX*0.96,3,0),COLORGREEN;红灯买:STICKLINE(密码1>密码3,HLMAX,HLMAX*0.96,3,0),COLORRED;STICKLINE(1,HLMAX*0.98,HLMAX*0.98,3,0),COLORWHITE;STICKLINE(1,HLMAX*0.93,HLMAX*0.89,3,0),COLORRED;绿灯卖:STICKLINE(密码2<=密码4,HLMAX*0.93,HLMAX*0.89,3,0),COLORGREEN; STICKLINE(1,HLMAX*0.91,HLMAX*0.91,3,0),COLORWHITE;操作段1:STICKLINE(密码1>(密码3) AND C>密码 2 OR 密码2>密码4,HLMAX*0.82,HLMAX*0.86,3,0),COLORRED;操作段2:STICKLINE(C>密码 2 AND 密码1>密码3,HLMAX*0.82,HLMAX*0.86,3,0),COLORMAGENTA;操作段3:STICKLINE(密码1<密码 3 AND 密码2>密码4,HLMAX*0.82,HLMAX*0.86,3,0),COLORYELLOW;STICKLINE(密码1>(密码3) AND C>密码2 OR 密码2>密码4 OR C>密码2 AND 密码1>密码3,HLMAX*0.84,HLMAX*0.84,3,0),COLORWHITE;。

通达信指标公式源码精准画线公式

通达信指标公式源码精准画线公式

N1:=20;N2:=10;N3:=5;AA:=REF(H,N1)=HHV(H,2*N1+1);QY:=BACKSET(AA,N1+1);CC:=FILTER(QY,N1) AND H=HHV(H,N1+1);DDD:=BARSLAST(CC);GDTS:=IF(CC,CURRBARSCOUNT,0);DINGBU:=IF(DDD,REF(H,DDD),H);{顶部}DINGBUTS:=IF(DDD,REF(GDTS,DDD),GDTS);DINGBU1:=REF(DINGBU,DDD+1);GDCS1:=CONST(DINGBUTS);DINGBUTS1:=REF(DINGBUTS,DDD+1);GDCS2:=CONST(DINGBUTS1);DINGBU2:=REF(DINGBU1,DDD+1);MM:=IF(CURRBARSCOUNT>GDCS2,0,1);{DRAWLINE(CURRBARSCOUNT=GDCS2,H,ISLASTBAR,REF(H,GDCS2-1),1),CO LOR0055FF,POINTDOT,LINETHICK2;DRAWLINE(CURRBARSCOUNT=GDCS1,H,ISLASTBAR,REF(H,GDCS1-1),1),COL ORYELLOW,POINTDOT,LINETHICK2;}AA1:=REF(L,N1)=LLV(L,2*N1+1);QY1:=BACKSET(AA1,N1+1);CC1:=FILTER(QY1,N1) AND L=LLV(L,N1+1);DD1:=BARSLAST(CC1);DDTS:=IF(CC1,CURRBARSCOUNT,0);YDB:=IF(DD1,REF(L,DD1),L);DDTS1:=IF(DD1,REF(DDTS,DD1),DDTS);DDCS1:=CONST(DDTS1);ZDB:=REF(YDB,DD1+1);DDTS2:=REF(DDTS1,DD1+1);DDCS2:=CONST(DDTS2);{DRAWLINE(CURRBARSCOUNT=DDCS2,L,ISLASTBAR,REF(L,DDCS2-1),1),COLOR0055FF,POINTDOT,LINETHICK2;DRAWLINE(CURRBARSCOUNT=DDCS1,L,ISLASTBAR,REF(L,DDCS1-1),1),COL ORYELLOW,POINTDOT,LINETHICK2;}LAA:=REF(H,N2)=HHV(H,2*N2+1);LQY:=BACKSET(LAA,N2+1);LCC:=FILTER(LQY,N2) AND H=HHV(H,N2+1);LDDD:=BARSLAST(LCC);LGDTS:=IF(LCC,CURRBARSCOUNT,0);LDINGBU:=IF(LDDD,REF(H,LDDD),H);{顶部}LDINGBUTS:=IF(LDDD,REF(LGDTS,LDDD),LGDTS);LDINGBU1:=REF(LDINGBU,LDDD+1);LGDCS1:=CONST(LDINGBUTS);LDINGBUTS1:=REF(LDINGBUTS,LDDD+1);LGDCS2:=CONST(LDINGBUTS1);LDINGBU2:=REF(LDINGBU1,LDDD+1);LMM:=IF(CURRBARSCOUNT>LGDCS2,0,1);{DRAWLINE(CURRBARSCOUNT=LGDCS2,H,ISLASTBAR,REF(H,LGDCS2-1),1), COLOR0055FF,POINTDOT;DRAWLINE(CURRBARSCOUNT=LGDCS1,H,ISLASTBAR,REF(H,LGDCS1-1),1),C OLORYELLOW,POINTDOT;}LAA1:=REF(L,N2)=LLV(L,2*N2+1);LQY1:=BACKSET(LAA1,N2+1);LCC1:=FILTER(LQY1,N2) AND L=LLV(L,N2+1);LDD1:=BARSLAST(LCC1);LDDTS:=IF(LCC1,CURRBARSCOUNT,0);LYDB:=IF(LDD1,REF(L,LDD1),L);LDDTS1:=IF(LDD1,REF(LDDTS,LDD1),LDDTS);LDDCS1:=CONST(LDDTS1);LZDB:=REF(LYDB,LDD1+1);LDDTS2:=REF(LDDTS1,DD1+1);LDDCS2:=CONST(LDDTS2);DDYL2:=DRAWLINE(CURRBARSCOUNT=LGDCS2,H,CURRBARSCOUNT=LGDC S1,H,1) COLORWHITE;DDZC2:=DRAWLINE(CURRBARSCOUNT=LDDCS2,L,CURRBARSCOUNT=LDDC S1,L,1) COLORWHITE;ZGSTAR:=(DDYL2+DDZC2)/2;ZGEND:=CONST((DDYL2+DDZC2)/2);STARDAY:=IF(DDCS2<GDCS2,DDCS2,GDCS2);LLAA:=REF(H,N3)=HHV(H,2*N3+1);LLQY:=BACKSET(LLAA,N3+1);LLCC:=FILTER(LLQY,N3) AND H=HHV(H,N3+1);LLDDD:=BARSLAST(LLCC);LLGDTS:=IF(LLCC,CURRBARSCOUNT,0);LLDINGBU:=IF(LLDDD,REF(H,LLDDD),H);{顶部}LLDINGBUTS:=IF(LLDDD,REF(LLGDTS,LLDDD),LLGDTS);LLDINGBU1:=REF(LLDINGBU,LLDDD+1);LLGDCS1:=CONST(LLDINGBUTS);LLDINGBUTS1:=REF(LLDINGBUTS,LLDDD+1);LLGDCS2:=CONST(LLDINGBUTS1);LLDINGBU2:=REF(LLDINGBU1,LLDDD+1);LLMM:=IF(CURRBARSCOUNT>LGDCS2,0,1);{DRAWLINE(CURRBARSCOUNT=LLGDCS2,H,ISLASTBAR,REF(H,LLGDCS2-1),1 ),COLOR0055FF,POINTDOT;DRAWLINE(CURRBARSCOUNT=LLGDCS1,H,ISLASTBAR,REF(H,LLGDCS1-1),1) ,COLORYELLOW,POINTDOT;}LLAA1:=REF(L,N3)=LLV(L,2*N3+1);LLQY1:=BACKSET(LLAA1,N3+1);LLCC1:=FILTER(LLQY1,N3) AND L=LLV(L,N3+1);LLDD1:=BARSLAST(LCC1);LLDDTS:=IF(LLCC1,CURRBARSCOUNT,0);LLYDB:=IF(LLDD1,REF(L,LLDD1),L);LLDDTS1:=IF(LLDD1,REF(LLDDTS,LLDD1),LDDTS);LLDDCS1:=CONST(LLDDTS1);LLZDB:=REF(LLYDB,LLDD1+1);LLDDTS2:=REF(LLDDTS1,DD1+1);LLDDCS2:=CONST(LLDDTS2);GDYL3:=DRAWLINE(CURRBARSCOUNT=LLGDCS2,H,CURRBARSCOUNT=LLG DCS1,H,1) COLORYELLOW;DDZC3:=DRAWLINE(CURRBARSCOUNT=LLDDCS2,L,CURRBARSCOUNT=LLDD CS1,L,1) COLORYELLOW;LZGSTAR:=(GDYL3+DDZC3)/2;LZGEND:=CONST((GDYL3+DDZC3)/2);LSTARDAY:=IF(LLDDCS2<LLGDCS2,LLDDCS2,LLGDCS2);GDYL1:=DRAWLINE(CURRBARSCOUNT=GDCS2,H,CURRBARSCOUNT=GDCS1 ,H,1) COLORRED;DDZC1:=DRAWLINE(CURRBARSCOUNT=DDCS2,L,CURRBARSCOUNT=DDCS1, L,1) COLORRED;长线压力:DDZC1+(GDYL1-DDZC1)*0.809,COLORRED;长线支撑:DDZC1+(GDYL1-DDZC1)*0.191,COLORRED;中线压力:DDZC2+(DDYL2-DDZC2)*0.809,COLORGREEN;中线支撑:DDZC2+(DDYL2-DDZC2)*0.191,COLORGREEN;短线压力:DDZC3+(GDYL3-DDZC3)*0.809,COLORBLUE;短线支撑:DDZC3+(GDYL3-DDZC3)*0.191,COLORBLUE;L中轨:DRAWLINE(CURRBARSCOUNT=LSTARDAY,LZGSTAR,ISLASTBAR,LZGEND,1 ),COLORYELLOW;中轨:DRAWLINE(CURRBARSCOUNT=STARDAY,ZGSTAR,ISLASTBAR,ZGEND,1),COLORWHITE;长GDYL:DRAWLINE(CURRBARSCOUNT=GDCS2,H,CURRBARSCOUNT=GDCS1,H, 1) COLORRED,POINTDOT;长DDZC:DRAWLINE(CURRBARSCOUNT=DDCS2,L,CURRBARSCOUNT=DDCS1,L, 1) COLORRED,POINTDOT;中DDYL:DRAWLINE(CURRBARSCOUNT=LGDCS2,H,CURRBARSCOUNT=LGDCS1, H,1) COLORWHITE,POINTDOT;中DDZC:DRAWLINE(CURRBARSCOUNT=LDDCS2,L,CURRBARSCOUNT=LDDCS1, L,1) COLORWHITE,POINTDOT;短GDYL:DRAWLINE(CURRBARSCOUNT=LLGDCS2,H,CURRBARSCOUNT=LLGDCS 1,H,1) COLORYELLOW,POINTDOT;短DDZC:DRAWLINE(CURRBARSCOUNT=LLDDCS2,L,CURRBARSCOUNT=LLDDCS 1,L,1) COLORYELLOW,POINTDOT;。

通达信三个公式源码准确率90%以上超级指标精准买卖绝世指标

通达信三个公式源码准确率90%以上超级指标精准买卖绝世指标

通达信三个公式源码准确率90%以上超级指标精准买卖绝世指标1 超级指标指标公式:买卖提示非常明显(适合通达信)指标源码如下:M:3 100 60N 3 100 30散户线: 100*(HHV(HIGH,M)-CLOSE)/(HHV(HIGH,M)-LLV(LOW,M));RSV:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;K:=SMA(RSV,5,1);D:=SMA(K,3,1);J:=3*K-2*D;主力线:EMA(J,6),COLORYELLOW;VAR2:=REF(LOW,1);VAR3:=SMA(ABS(LOW-VAR2),3,1)/SMA(MAX(LOW-VAR2,0),3,1)*100;VAR4:=EMA(IF(CLOSE*1.3,VAR3*10,VAR3/10),3);VAR5:=LLV(LOW,30);VAR6:=HHV(VAR4,30);VAR7:=IF(MA(CLOSE,58),1,0);VAR8:=EMA(IF(LOW<=VAR5,(VAR4+VAR6*2)/2,0),3)/618*VA R7;VAR9:=IF(VAR8>100,100,VAR8);吸筹:STICKLINE(VAR9>-120,0,VAR9,2,5),COLORMAGENTA;AA3:=(HHV(HIGH,21)-CLOSE)/(HHV(HIGH,21)-LLV(LOW,21))*100-10;AA4:=(CLOSE-LLV(LOW,21))/(HHV(HIGH,21)-LLV(LOW,21))*100;AA5:=SMA(AA4,13,8);走势:CEILING(SMA(AA5,13,8)),COLORRED,LINETHICK2;AA6:=SMA(AA3,21,8);买观注: STICKLINE(走势-AA6<-65,0,7,15,1);DRAWICON(FILTER(J>REF(J,1)AND 走势>=REF(走势,1)AND 走势<25 ,5),走势,4);卖观注: STICKLINE(走势-AA6>85,98,90,15,1),COLORFFFF00;DRAWICON(FILTER(J<REF(J,1)AND 走势<=REF(走势,1)AND J>85 ,5),J,5);DIF1:=EMA(CLOSE,7)-EMA(CLOSE,19),COLORWHITE;DEA1:=EMA(DIF1,9);MACD1:=(DIF1-DEA1)*100,COLORSTICK;STICKLINE(MACD1>REF(MACD1,1) AND MACD1>0,0,MACD1,0,0),COLORRED;STICKLINE(MACD1<=REF(MACD1,1) AND MACD1>0,0,MACD1,0,0),COLORYELLOW;STICKLINE(MACD1<REF(MACD1,1) AND MACD1<0,0,MACD1,0,0),COLOR00FF00;STICKLINE(MACD1>=REF(MACD1,1) AND MACD1<0,0,MACD1,0,0),COLORMAGENTA;STICKLINE(C>0,0,0,50,1),COLORBLUE;RSV1:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;K日:SMA(RSV1,3,1),COLORWHITE;D日:SMA(K日,3,1),COLORYELLOW;J日:3*K日-2*D日,COLORFF00FF;底部:0,COLORF00FF0,LINETHICK2;DRAWICON(CROSS(J日,底部),底部,1);2 精准买卖支撑价:LLV(LOW,19),LINETHICK2 , COLOR00FF00;阻力价:HHV(HIGH,19),COLORBLUE, LINETHICK2;VAR1:=EMA(CLOSE,12)-EMA(CLOSE,26);VAR2:=EMA(VAR1,9);VAR3:=(CLOSE*2.5/100+CLOSE);VAR4:EMA(C,3);VAR5:=LLV(HIGH,240);VAR6:=100*(CLOSE-VAR5)/VAR5;VAR7:=REF(LLV(CLOSE,480),1);VAR8:=REF(HHV(CLOSE,480),1);VAR9:=100*(CLOSE-VAR7)/(VAR8-VAR7);VARA:=(CLOSE-LLV(CLOSE,981))/(HHV(CLOSE,981)-LLV(CLOSE,981))*100;VARB:=(CLOSE-LLV(CLOSE,393))/(HHV(CLOSE,393)-LLV(CLOSE,393))*100;VARC:=(CLOSE-LLV(LOW,981))/(HHV(HIGH,981)-LLV(LOW,981))*100;VARD:=(CLOSE-LLV(LOW,393))/(HHV(HIGH,393)-LLV(LOW,393))*100;VARE:=VARC>98.5 OR VARD>98.5;VARF:=EMA(100*(CLOSE-LLV(LOW,100))/(HHV(HIGH,100)-LLV(LOW,100)),5)/4;VAR13:=VARA=0 AND VARC=0 AND VAR6<0;VAR14:=VARA=100 AND VARC=100;VAR15:=VARB=0 OR VARD=0 AND VAR9<0;VAR16:=VARB=100 AND VARD=100;VAR17:=VAR6<0 AND VAR9<0;VAR18:=VAR13 AND VAR15;VAR19:=VAR14 AND VAR16;VAR1B:=SMA(MAX(CLOSE-REF(CLOSE,1),0),49,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),6,1)*100;VAR1C:=SMA(MAX(CLOSE-REF(CLOSE,1),0),14,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),14,1)*100;VAR1D:=BARSCOUNT(CLOSE);VAR1E:=VAR1B<20 AND VAR1C<23 AND VAR1D>35;VAR1F:=VAR1E AND COUNT(VAR1E,1)=1;VAR20:=REF(CLOSE,1);VAR21:=SMA(MAX(CLOSE-VAR20,0),34,1)/SMA(ABS(CLOSE-VAR20),7,1)*100;VAR22:=SMA(MAX(CLOSE-VAR20,0),13,1)/SMA(ABS(CLOSE-VAR20),13,1)*100;VAR23:=BARSCOUNT(CLOSE);VAR24:=VAR21<20 AND VAR22<23 AND VAR23>35;VAR25:=VARA=0 AND VARF<1.2 AND VAR17;VAR27:=VAR18 AND VARF<1.2 AND VAR17;VAR29:=SUM(HIGH-OPEN,77)/SUM(OPEN-LOW,77)*100;VAR2A:=SUM(MAX(0,HIGH-REF(CLOSE,1)),77)/SUM(MAX(0,REF(CLOSE,1)-LOW),77)*100;VAR2B:=CROSS(VAR29,69) AND CROSS(VAR2A,80)<150;VAR2C:=VAR24 AND VAR1F AND COUNT(VAR24,30)=1;买点:=VAR25 AND VAR2B;绝对卖点:=(VAR19 OR VARA)AND VARF>23 OR VARE ;VAR2D:=VAR1F AND VAR2C AND VAR25;股海万元户:=(CLOSE/REF(CLOSE,1)>1.04 AND (CLOSE>10.8 AND CLOSE<10.83 OR CLOSE>6.86 AND CLOSE<6.88 OR CLOSE>13.82 AND CLOSE<13.84 OR CLOSE>7.28 AND CLOSE<7.3 OR CLOSE>12.4 AND CLOSE<12.42 OR CLOSE>22.33 AND CLOSE<22.35 OR CLOSE>4.68 AND CLOSE<4.7 OR CLOSE>26.29 AND CLOSE<26.31 OR CLOSE>7.65 AND CLOSE<7.67 OR CLOSE>13.4 AND CLOSE<13.42 OR CLOSE>7.58 AND CLOSE<7.6 OR CLOSE>20.43 AND CLOSE<20.45 ORCLOSE>19.57 AND CLOSE<19.59 OR CLOSE>6.26 AND CLOSE<6.28 OR CLOSE>7.14 AND CLOSE<7.16 OR CLOSE>6.61 AND CLOSE<6.63 OR CLOSE>11.9 AND VOL<11.92 OR CLOSE>6.7 AND CLOSE<6.72 OR CLOSE>8.19 AND CLOSE<8.21));DRAWTEXT(FILTER(绝对卖点>0,3),H,'别贪'), COLOR00FF00;DRAWTEXT(股海万元户>0,L,'☆追涨'),COLORYELLOW ;DRAWICON(买点>0,L,4);DRAWTEXT(买点>0,L,'扫描神针'),COLORF00FF0;DRAWTEXT(VARF<0.7 AND VAR27 AND VAR25>0,L,'万元'),COLORYELLOW;STICKLINE(VAR2D>0,O,C,10,0), COLORRED;DRAWTEXT(VAR2D>0,L,'大方神针'),COLORRED;DRAWICON(COUNT(REF(VAR4,1)<REF(VAR4,2),5)=5 AND VAR4>REF(VAR4,1),L*0.98,5);DRAWICON(FILTER(COUNT(VAR6<0,5)ANDCROSS(VAR6,0)AND VARF>REF(VARF,1)AND C>O,3),L,1);DRAWICON(FILTER(REF(VAR4,1)>REF(VAR4,2)ANDVAR4<REF(VAR4,1)AND VARF>17 AND VAR1>VAR2,5),H,2);DRAWICON(阻力价>REF(阻力价,1)AND CROSS(阻力价,VAR3)AND C<O,H*1.02,15);DIF1:=EMA(CLOSE,7)-EMA(CLOSE,19),COLORWHITE;DEA1:=EMA(DIF1,9);MACD1:=(DIF1-DEA1)*100,COLORSTICK;STICKLINE(MACD1>REF(MACD1,1) AND MACD1>0,0,MACD1,0,0),COLORRED;STICKLINE(MACD1<=REF(MACD1,1) AND MACD1>0,0,MACD1,0,0),COLORYELLOW;STICKLINE(MACD1<REF(MACD1,1) AND MACD1<0,0,MACD1,0,0),COLOR00FF00;STICKLINE(MACD1>=REF(MACD1,1) ANDMACD1<0,0,MACD1,0,0),COLORMAGENTA;STICKLINE(C>0,0,0,50,1),COLORBLUE;RSV1:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;K日:SMA(RSV1,3,1),COLORWHITE;D日:SMA(K日,3,1),COLORYELLOW;J日:3*K日-2*D日,COLORFF00FF;底部:0,COLORF00FF0,LINETHICK2;DRAWICON(CROSS(J日,底部),底部,1);3 绝世指标GLL:-4;顶:80,COLORFFA500;大顶:100,COLORBLUE;VAR1:=(CLOSE-LLV(LOW,60))/(HHV(HIGH,60)-LLV(LOW,60))*80;VAR2:=SMA(VAR1,10,1);慢速:SMA(VAR2,5,1),COLORRED;RSV:= ((HHV(HIGH,9)-CLOSE)/(HHV(HIGH,9)-LLV(LOW,9))*100)-70;RSV1:= (CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;FATK:=SMA(RSV1,3,1);形态:SMA(FATK,3,1),COLORBB24DB;VARA:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;VARB:=SMA(VARA,3,1);VARC:=SMA(VARB,3,1);加速: EMA(3*VARB-2*VARC,3),COLORYELLOW;底:6,COLOR00BF00;大底:-6,COLOR007300;VAR11:=LLV(LOW,5)=LLV(LOW,45) AND CLOSE>=OPEN*1.04;VAR22:=CLOSE>(REF(HIGH,1)+REF(LOW,1))/2;买入:=VAR11 AND VAR22,STICK,LINETHICK2,COLORRED;VAR3:=REF(CLOSE,1);VAR4:=SMA(MAX(CLOSE-VAR3,0),6,1)/SMA(ABS(CLOSE-VAR3),6,1)*100;卖出:=CROSS(80,VAR4),STICK,LINETHICK2,COLORGREEN;{波段介入点}A1:=REF(CLOSE,2);A2:=SMA(MAX(CLOSE-A1,0),7,1)/SMA(ABS(CLOSE-A1),7,1)*100;波段介入点:IF(A2<19,19,0)COLORWHITE;。

通达信指标公式源码超级精准布林线

通达信指标公式源码超级精准布林线

公式源码:S:=2;P:=0;VARA:=(((CLOSE - EMA(CLOSE,13)) / EMA(CLOSE,13)) * (0 - 100));趋势线:=EMA(((VARA/10)+EMA(CLOSE,10)),3);VARB:=(OPEN+HIGH+LOW)/3;VARC:=EMA(VARB,4);行情线:=VARC;BUY11:=IF(CROSS(行情线,趋势线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线>趋势线),1,0);DRAWTEXT(CROSS(行情线,趋势线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线>趋势线),LOW*0.98,'▲'),COLOR0000FF;趋势线),LOW*0.97,'∣'),COLOR0000FF;DRAWTEXT(CROSS(行情线,趋势线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线>趋势线),LOW*0.975,'‖'),COLOR0000FF;DRAWTEXT(CROSS(行情线,趋势线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线>趋势线),LOW*0.96,'∣'),COLOR0000FF;DRAWTEXT(CROSS(行情线,趋势线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线>趋势线),LOW*0.97,'‖'),COLOR0000FF;DRAWTEXT(CROSS(行情线,趋势线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线>趋势线),LOW*0.95,'∣'),COLOR0000FF;DRAWTEXT(CROSS(行情线,趋势线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线>趋势线),LOW*0.965,'‖'),COLOR0000FF;DRAWTEXT(CROSS(趋势线,行情线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线<趋势线),HIGH*1.02,'▼'),COLOR00FF00;DRAWTEXT(CROSS(趋势线,行情线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线<趋势线),HIGH*1.030,'∣'),COLOR00FF00;DRAWTEXT(CROSS(趋势线,行情线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线<趋势线),HIGH*1.025,'‖'),COLOR00FF00;DRAWTEXT(CROSS(趋势线,行情线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线<趋势线),HIGH*1.040,'∣'),COLOR00FF00;DRAWTEXT(CROSS(趋势线,行情线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线<趋势线),HIGH*1.03,'‖'),COLOR00FF00;趋势线),HIGH*1.050,'∣'),COLOR00FF00;DRAWTEXT(CROSS(趋势线,行情线) OR (REF(行情线,1)=REF(趋势线,1) AND 行情线<趋势线),HIGH*1.035,'‖'),COLOR00FF00;FF:=EMA(CLOSE,3);MA15:=EMA(CLOSE,21);FA:=IF(CROSS(FF,MA15),1,0);TR1:=MAX(MAX((HIGH - LOW),ABS(REF(CLOSE,1) - HIGH)),ABS(REF(CLOSE,1) - LOW));ATR:=MA(TR1,14);AA:=(HHV(HIGH,20) - (2 * ATR));BB:=CROSS(CLOSE,REF(HHV(HIGH,55),1));SSS:=CROSS(MIN(MA(CLOSE,13),AA),CLOSE);BBB:=BARSLAST(BB);SSSB:=BARSLAST(SSS);B1:=((BBB = 0) AND (REF(SSSB,1) < REF(BBB,1)));B1B:=BARSLAST(B1);B2:=((((BB = 1) AND (B1B < SSSB)) AND (B1B > 0)) AND (COUNT(BB,SSSB) < 3));B2B:=BARSLAST(B2);B3:=((((BB = 1) AND (B2B < B1B)) AND (COUNT(BB,SSSB) < 4)) AND(COUNT(BB,SSSB) > 2));DRAWTEXT((B1=1 AND 行情线>=趋势线AND BUY11=0) OR (B2=1 AND 行情线>=趋势线AND BUY11=0),LOW*0.98,'▲'),COLORFF00FF;A:=(3*CLOSE+LOW+OPEN+HIGH)/6;X:=(20*A+19*REF(A,1)+18*REF(A,2)+17*REF(A,3)+16*REF(A,4)+15*REF(A,5)+14*REF(A,6)+13*REF(A,7)+12*REF(A,8)+11*REF(A,9)+10*REF(A,10)+9*REF(A,11)+8* REF(A,12)+7*REF(A,13)+6*REF(A,14)+5*REF(A,15)+4*REF(A,16)+3*REF(A,17)+2*REF(A,18)+REF(A,20))/210;Y:=EMA(X,13);加仓A:=SMA(EMA((C-REF(C,1))/REF(C,1),5)*100,3,1)*10;DRAWTEXT(FILTER((CROSS(加仓A,0) OR CROSS(CLOSE,Y)) AND 行情线>=趋势线AND BUY11=0 AND FA=0,3),LOW*0.98,'▲'),COLORFF00FF;加仓:=(B1=1 AND 行情线>=趋势线AND BUY11=0) OR (B2=1 AND 行情线>=趋势线AND BUY11=0) OR FILTER((CROSS(加仓A,0) OR CROSS(CLOSE,Y)) AND 行情线>=趋势线AND BUY11=0 AND FA=0,3);STICKLINE(加仓,C,O,6,1),COLORFF00FF;STICKLINE(加仓,OPEN,CLOSE,4.5,1),COLORFF0099;STICKLINE(加仓,OPEN,CLOSE,3,0),COLORFF00CC;STICKLINE(加仓,OPEN,CLOSE,2,0),COLORFF00FF;VARJ1:=REF(CLOSE,1);VARJ2:=((SMA(MAX(CLOSE-VARJ1,0),6,1))/(SMA(ABS(CLOSE-VARJ1),6,1)))*(100);减仓A:=CROSS(85,VARJ2);DRAWTEXT(减仓A AND 行情线>=趋势线,HIGH*1.02,'▼'),COLORYELLOW;MTM:=C-REF(C,1);DX:=100*EMA(EMA(MTM,6),6)/EMA(EMA(ABS(MTM),6),6);DY:=HHV(DX,2)=HHV(DX,7) AND COUNT(DX>50,2) AND CROSS(MA(DX,2),DX); LC:=REF(CLOSE,1);RSI:=SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100;减仓B:=FILTER(CROSS(84,RSI) OR DY,5);DRAWTEXT(减仓B AND 行情线>=趋势线,H*1.02,'▼'),COLORYELLOW;减仓:=减仓A OR 减仓B;DRAWTEXT(FA AND BUY11=0,(LOW * 0.98),'□□'),COLOR0099FF;底背离:=FA AND BUY11=0;{TY:=C;HD:=FILTER(BACKSET(FILTER(REF(TY,10)=HHV(TY,2*10+1),10),10+1),10);LD:=FILTER(BACKSET(FILTER(REF(TY,10)=LLV(TY,2*10+1),10),10+1),10);A2:=REF(C,BARSLAST(HD));B2A:=REF(C,BARSLAST(LD));T1:=BARSLAST(HD)<BARSLAST(LD) AND NOT(HD) ;T2:=BARSLAST(HD)>BARSLAST(LD) AND NOT(LD);顶:IF(T1,A2,A2),COLOR00FF00,POINTDOT,LINETHICK2;STICKLINE(T1,A2,A2,9,0),COLOR00FF00;底:IF(T2,B2A,B2A),COLORFF00FF,POINTDOT,LINETHICK2;STICKLINE(T2,B2A,B2A,9,0),COLORFF00FF;}VAR2:=(C+L+O+H)/4;多头线:=(20*VAR2+19*REF(VAR2,1)+18*REF(VAR2,2)+17*REF(VAR2,3)+16*REF(VAR2,4) +15*REF(VAR2,5)+14*REF(VAR2,6)+13*REF(VAR2,7)+12*REF(VAR2,8)+11*REF(VAR 2,9)+10*REF(VAR2,10)+9*REF(VAR2,11)+8*REF(VAR2,12)+7*REF(VAR2,13)+6*REF( VAR2,14)+5*REF(VAR2,15)+4*REF(VAR2,16)+3*REF(VAR2,17)+2*REF(VAR2,18)+RE F(VAR2,19))/210;空头线:=EMA(多头线,4);STICKLINE(多头线>空头线,多头线,空头线,4,1),COLORYELLOW;STICKLINE(多头线<空头线,多头线,空头线,4,1),COLORCCCCCC;压制:DRAWLINE(C=HHV(C,60),HHV(H,3),C=HHV(C,30) ANDC<HHV(C,45),HHV(HIGH,1),P),COLORYELLOW;依托:DRAWLINE(L=LLV(L,60),LLV(L,3),L=LLV(L,30) ANDL>LLV(L,45),LLV(L,3),P),COLORGREEN;E:=(REF(H,S-1)+REF(L,S-1)+REF(C,S-1))/3;CRTP:=2*E+(REF(H,S-1)-2*REF(L,S-1));CRZL:=2*E-REF(L,S-1);CRZC:=2*E-REF(H,S-1);CRFZ:=2*E-(2*REF(H,S-1)-REF(L,S-1));高:=CONST(CRTP),COLORRED;阻:=CONST(CRZL),COLORC7C9FF;平:=CONST(E),COLORBLUE;支:=CONST(CRZC),COLOR7C9CFF;反:=CONST(CRFZ),COLORDD00DD;AH:DRAWLINE(S>1&&CURRBARSCOUNT=S+1,高,ISLASTBAR,高,1),COLORRED; STICKLINE(ISLASTBAR AND C>(高+阻)*0.5,高,高,22,0),COLORRED;NH:DRAWLINE(S>1&&CURRBARSCOUNT=S,阻,ISLASTBAR,阻,1),COLORC7C9FF; STICKLINE(ISLASTBAR AND C>(支+平)*0.5,阻,阻,18,0),COLORC7C9FF;CDP:DRAWLINE(S>1&&CURRBARSCOUNT=S+3,平,ISLASTBAR,平,1),COLORBLUE; STICKLINE(ISLASTBAR,平,平,27,0),COLORBLUE;NL:DRAWLINE(S>1 &&CURRBARSCOUNT=S,支,ISLASTBAR,支,1),COLOR7C9CFF; STICKLINE(ISLASTBAR AND C<(阻+平)*0.5 ,支,支,18,0),COLOR7C9CFF;AL:DRAWLINE(S>1&&CURRBARSCOUNT=S+1,反,ISLASTBAR,反,1),COLORDD00DD; STICKLINE(ISLASTBAR AND C<(反+支)*0.5,反,反,22,0),COLORDD00DD;TBP:2*REF(C,S)-REF(C,(S+2)),COLORYELLOW,NODRAW;TXR:=MAX(MAX((REF(H,S-1)-REF(L,S-1)),ABS(REF(C,S-1)-REF(H,S))),ABS(REF(C,S-1) - REF(L,S))),NODRAW;TPS:=CONST(E-TXR),NODRAW;TMB:=CONST(E+TXR),NODRAW;PS:DRAWLINE(S>1&&CURRBARSCOUNT=S+2,TPS,ISLASTBAR,TPS,S),COLORLICY AN;STICKLINE(ISLASTBAR AND C<平,TPS,TPS,25,0),COLORLICYAN;MB:DRAWLINE(S>1&&CURRBARSCOUNT=S+2,TMB,ISLASTBAR,TMB,S),COLORLIG RAY;STICKLINE(ISLASTBAR AND C>平,TMB,TMB,25,0),COLORLIGRAY;RMB:=CONST(BBI),NODRAW;RR:DRAWLINE(S>1&&CURRBARSCOUNT=2+2,RMB,ISLASTBAR,RMB,1),COLORLIR ED,CIRCLEDOT;强D:=HHV(((HIGH + REF(C,1)+REF(LOW,1))/3),17),COLORRED,{NODRAW};强K:=HHV(((HIGH+C+REF(LOW,1))/3),17),COLORYELLOW,POINTDOT{MAX(强DNODRAW};QD50:=((强D+强K)*0.5+MAX(强D,强K))*0.5;DRAWBAND(强D,RGB(0,153,0),QD50,RGB(255,0,0));弱D:=LLV(((REF(HIGH,1)+REF(C,1)+LOW)/3),17*(P+1)),COLORGREEN;弱K:=LLV(((HIGH+C+REF(LOW,1))/3),17*(P+1)),COLORYELLOW,POINTDOT;RD50:=((弱D+弱K)*0.5+MIN(弱D,弱K))*0.5;XO:=(强D+弱D)*0.5,COLORMAGENTA;DRAWBAND(弱D,RGB(255,255,53),RD50,RGB(0,102,255));。

通达信黄金精准买卖拐点主图指标公式副图源码

通达信黄金精准买卖拐点主图指标公式副图源码

通达信黄金精准买卖拐点主图指标公式副图源码SHORT:=12;LONG:=26;M:=12;DIF:=EMA(CLOSE,SHORT)-EMA(CLOSE,LONG);DEA:=EMA(DIF,M);MACD:=2*(DIF-DEA);KK:=IF(DIF>DEA,5,-5);JCSC:=(M-1)/(M+1)*DEA/(1-2/(M+1));{计算出金叉死叉时的DIFF 值}DD:=(MACD/2+(DEA*(M-1)/(M+1)))/(1-2/(M+1));{计算出明日MACD=MACD时的DIFF值}DIF拐头价:=(DIF*(SHORT+1)*(LONG+1)-(LONG+1)*(SHORT-1)*EMA(C,S HORT)+(SHORT+1)*(LONG-1)*EMA(C,LONG))/(2*((LONG+1)-(S HORT+1)))COLORGREEN,POINTDOT;金死叉价:=(JCSC*(SHORT+1)*(LONG+1)-(LONG+1)*(SHORT-1)*EMA(C, SHORT)+(SHORT+1)*(LONG-1)*EMA(C,LONG))/(2*((LONG+1)-(S HORT+1))),NODRAW;柱变向价:=(DD*(SHORT+1)*(LONG+1)-(LONG+1)*(SHORT-1)*EMA(C,S HORT)+(SHORT+1)*(LONG-1)*EMA(C,LONG))/(2*((LONG+1)-(S HORT+1))),COLORYELLOW,POINTDOT;黄铢消失见顶:=IF(柱变向价>=DIF拐头价,柱变向价,DRAWNULL),COLORYELLOW,CIRCLEDOT,LINETHICK1;上拐:IF(DIF拐头价<柱变向价,DIF拐头价,DRAWNULL),COLORRED,LINETHICK4;下拐:IF(DIF拐头价>=柱变向价,DIF拐头价,DRAWNULL),COLOR33FF33,POINTDOT,LINETHICK4;ZJ:=上拐,COLOR0000FF;HY:=金死叉价,COLORFF00FF;IF(ZJ>REF(ZJ,1),ZJ,DRAWNULL),COLORRED,LINETHICK2;IF(HY>REF(HY,1),HY,DRAWNULL),COLORMAGENTA,LINETHICK2, NODRAW;IF(HY<REF(HY,1),HY,DRAWNULL),COLORBLUE,LINETHICK2,NOD RAW;STICKLINE(C>ZJ AND C>O,H,C,0,0 ),COLORRED;STICKLINE(C>ZJ AND C>O,L,O,0,0 ),COLORRED;STICKLINE(C>ZJ AND C>O,O,C,2.8,1),COLORRED;STICKLINE(C>ZJ AND C<=O,H,L,0,0 ),COLORRED;STICKLINE(C>ZJ AND C<=O,O,C,2.8,0),COLORRED;STICKLINE(CLOSE=ZJ,H,L,3,0),COLORWHITE;STICKLINE(CLOSE<ZJ,H,L,0,0),COLORYELLOW;STICKLINE(CLOSE<ZJ,O,C,2.5,0),COLORYELLOW;STICKLINE(C<HY AND C>O,H,C,0,0),COLORCYAN;STICKLINE(C<HY AND C>O,O,L,0,0),COLORCYAN;STICKLINE(C<HY AND C>O,O,C,2.8,1),COLORCYAN;STICKLINE(C<HY AND C<=O,H,L,0,0),COLORCYAN;STICKLINE(C<HY AND C<=O,O,C,2.8,0),COLORCYAN;HD0:=CROSS(DIF,DEA);DRAWTEXT_FIX(C>O,0.005,0.92,0,' 众'),COLORWHITE;DRAWTEXT_FIX(C>O,0.01,0.92,0,' 号:代码部徵'),COLORWHITE;DRAWTEXT_FIX(C>O,0.09,0.92,0,'信:CXH99CXH99'),COLORWHITE;DRAWTEXT_FIX(C>O,0.01,0.75,0,'代编写或想要好指标选股公式模型'),COLORWHITE;DRAWTEXT_FIX(C>O,0.005,0.92,0,'公'),COLORWHITE;金收:REF(L,BARSLAST(HD0)),COLORYELLOW,DOTLINE;LD0:=CROSS(DEA,DIF);死收:REF(H,BARSLAST(LD0)),COLOR00FF00,DOTLINE;买入准备:DRAWICON(CROSS(柱变向价,DIF拐头价),上拐,34);卖出准备:DRAWICON(CROSS(DIF拐头价,柱变向价),下拐,35);SBL:=STRCAT(STRCAT(STRCAT(STRCAT(DYBLOCK,HYBLOCK),FG BLOCK),GNBLOCK),ZDBLOCK);DRAWTEXT_FIX(ISLASTBAR,0.01,0.005,0,SBL),COLORCYAN;。

通达信指标公式源码资金攻击量指标

通达信指标公式源码资金攻击量指标

{中轴设置}昨收:=DYNAINFO(3);HH:=DYNAINFO(5);LL:=DYNAINFO(6);FK:=MAX(HH-昨收,昨收-LL)*0.1;ZS:=昨收-FK*3.2;Q1:=昨收-FK*3.22;Q2:=昨收-1*FK*3.22;Q3:=昨收-5*FK*3.2;TJ:=FILTER(C,239)>0,NODRAW;TJJ:=SUM(TJ,0),NODRAW;TJA:=CONST(TJJ),NODRAW;流通盘:CAPITAL*100/100000000,NODRAW;资金流入:=SUM(IF(C>REF(C,1),V,0),FROMOPEN),STICK,COLORRED;资金流出:=-SUM(IF(C<REF(C,1),V,0),FROMOPEN),STICK,COLOR00FF00; 资金出入:=资金流入+资金流出,COLORSTICK;NN:=2400;HD:=HHV(资金出入,NN);LD:=LLV(资金出入,NN);最高:=CONST(HD),NODRAW;最低:=CONST(LD),NODRAW;HLMAX:=最高;HLMIN:=最低;HLMN1:=(HLMAX+HLMIN)/2;HLMN2:=HLMAX-HLMIN;HLMN3:=(100-0)/2*1.3;HLMN4:=(100-0)/1*1.3;中间价轴:=(50-HLMN3)*HLMN2/HLMN4+HLMN1;轴差:=最高-最低;DRAWBAND(资金出入,RGB(150,0,150),0,RGB(0,100,0));资金流量:资金出入,COLORFFFFFF,LINETHICK1;资金比:资金出入/SUM(V,FROMOPEN)*100,COLOR00FFFF,LINETHICK1;资金流量比:=IF(资金比>=0,(资金比+100)/2,100-ABS((资金比-100)/2));攻击量:=((HSL*0.50+REF(HSL,1)*0.33)+(REF(HSL,2)*0.17))*SUM(C,FROMOPEN)/FROMOPEN;攻击量A:=SUM(IF(C>REF(C,1),攻击量*V,0),FROMOPEN),COLOR0000FF,LINETHICK0;攻击量B:=-SUM(IF(C<REF(C,1),攻击量*V,0),FROMOPEN),COLOR00FF00,LINETHICK0;攻击流量:攻击量A+攻击量B,COLORSTICK;NOTEXT攻击线:攻击流量,COLORYELLOW,LINETHICK1;攻击比:攻击流量/SUM(V,FROMOPEN)*100,COLORRED,LINETHICK1;资金攻击度:=IF(攻击比>=0,(攻击比+50),100-ABS((攻击比-50)));{STICKLINE(资金流量A>0,资金流量A,0,1,0),COLOR0000FF;STICKLINE(资金流量B<0,资金流量B,0,1,0),COLORFF0000;}DRAWRECTREL(110,10,400,90,RGB(0,75,200));DRAWRECTREL(110,10,250,90,RGB(0,250,50));DRAWRECTREL(110,10,100+CONST(资金流量比*300/100),90,RGB(200,50,0));DRAWTEXT_FIX(1,0.000,0.00,0,STRCAT(STRCAT('【资金流量比】',CON2STR(资金流量比,2)),'%买')),COLORYELLOW;DRAWRECTREL(610,10,900,90,RGB(0,75,200));DRAWRECTREL(610,10,750,90,RGB(0,250,50));DRAWRECTREL(610,10,600+CONST(资金攻击度*300/100),90,RGB(175,50,0));DRAWTEXT_FIX(1,0.500,0.00,0,STRCAT(STRCAT('【资金攻击度】',CON2STR(资金攻击度,2)),' %买')),COLORYELLOW;量:=VOL,VOLSTICK;五日量:=MA(量,5),COLORWHITE;TT:=BARSCOUNT(C);{取得有效收盘价}均价黄:=SUM(C*V,TT)/SUM(V,TT);{分时均线的取值}量两步:=MA(V,5)>REF(MA(V,5),1) AND REF(MA(V,5),1)>REF(MA(V,5),2);价两步:= C>=REF(C,1) AND REF(C,1)>REF(C,2);价上岗量破5:=C>均价黄AND V>MA(V,5);量起爆:=V>=REF(V,1)*1;价创新高:=C>=HHV(C,0);量创新高:=V>=HHV(V,0);对昨日涨幅:=(C/DYNAINFO(3)-1)*100<=2.50;{涨幅控制2个点以内}每日一点:=量两步AND 价两步AND 价上岗量破5 AND 量起爆AND 价创新高AND 量创新高AND 对昨日涨幅;{计算收益、已爆分钟}VV:=BARSSINCE(每日一点)+1;首次起爆价:=REF(C,VV-1),NODRAW;起爆收益:(DYNAINFO(7)-首次起爆价)/首次起爆价*100,NODRAW;起爆时间:=REF(TIME/10000,VV),NODRAW;已爆分钟:=VV-1,NODRAW;{画出底线和红球}首次起爆量:=REF(VOL,VV-1);DRAWICON(已爆分钟>=2,最低,13);{出现红球,至少已经确认2分钟了};MMA30:=EMA(CLOSE,30);强弱界定:=IF(PERIOD=0 ,EMA(CLOSE,900),DRAWNULL);分时均价线:=SUM(C*V,240)/SUM(V,240),COLORYELLOW,LINETHICK2;BGTYU:=IF(DATE<=1150530,1,0);GHYJKU:=BETWEEN((DCLOSE*BGTYU)/(SUM(AMOUNT,BARSCOUNT((DCLOSE*BGTYU)))/SUM(VOL *100,BARSCOUNT((DCLOSE*BGTYU)))),1.05,0.95);VBNH:=IF(GHYJKU=0,MA((DCLOSE*BGTYU),BARSCOUNT((DCLOSE*BGTYU))),(SUM(AMOUNT,BARS COUNT((DCLOSE*BGTYU)))/SUM(VOL*100,BARSCOUNT((DCLOSE*BGTYU)))));二十☆:=EXPMA((DCLOSE/VBNH),20),COLORRED,LINETHICK1;六十★:=EXPMA((DCLOSE/VBNH),60),COLORLIGREEN,LINETHICK1;FAA:=BARSLAST(TIME=100000);FCC:=REF(HHV(C,0),FAA+1);FVV:=REF(HHV(V,0),FAA+1);ZF:=FCC/DYNAINFO(3)<1.05;XG1:=CROSS(C,FCC) AND V>FVV AND ZF,COLORWHITE;FAA1:=BARSLAST(TIME=110000);FCC1:=REF(HHV(C,0),FAA1+1);FVV1:=REF(HHV(V,0),FAA1+1);ZF1:=FCC1/DYNAINFO(3)<1.05;XG2:=CROSS(C,FCC1) AND V>FVV1 AND ZF1,COLORYELLOW;突破:=XG1 OR XG2,COLORRED;VT:=BARSSINCE(突破)+1;首次突破价:=REF(C,VT-1),NODRAW;突破收益:(DYNAINFO(7)-首次突破价)/首次突破价*100,NODRAW;拉升量:=IF(C>REF(C,1),VOL,0);昨拉升最高值:=CONST(FINDHIGH(拉升量,FROMOPEN,240,1)),LINETHICK1,COLORMAGENTA;今拉升最高值:=CONST(REF(HHV(拉升量,FROMOPEN),0)),COLORYELLOW,NODRAW;攻击力度:=今拉升最高值/昨拉升最高值,NODRAW;STICKLINE(FILTER(CROSS(拉升量,昨拉升最高值),30),最低+轴差*0.80,最低,1,0),COLORCYAN; STICKLINE(每日一点,最低+轴差*0.65,最低,1,0),COLORMAGENTA;STICKLINE(突破,最低+轴差*0.50,最低,1,0),COLORWHITE;STICKLINE(CROSS(EXPMA((DCLOSE/VBNH),60),EXPMA((DCLOSE/VBNH),120)),最低+轴差*0.35,最低,1,0),COLORYELLOW;STICKLINE(FILTER(BARSLAST(C<MIN(MMA30,强弱界定))<=20 AND CROSS(C,MAX(MMA30,强弱界定)),30),最低,最低+轴差*0.2,1,0),COLORGREEN;DRAWICON(FILTER(CROSS(拉升量,昨拉升最高值),30),最低+轴差*0.80,1);DRAWICON(每日一点,最低+轴差*0.65,1);DRAWICON(突破,最低+轴差*0.50,17);DRAWICON(FILTER(BARSLAST(C<MIN(MMA30,强弱界定))<=20 AND CROSS(C,MAX(MMA30,强弱界定)),30),最低+轴差*0.2,9);DRAWTEXT(FILTER(CROSS(拉升量,昨拉升最高值),30),最低+轴差*0.80,'☆攻击'),COLORCYAN; DRAWTEXT(每日一点,最低+轴差*0.65,'∠起爆'),COLORGREEN;DRAWNUMBER(每日一点,最低+轴差*0.55,首次起爆价),COLORGREEN;{DRAWTEXT(CURRBARSCOUNT=160,HHV(V,60)*0.9,'20线上行+日价K线突破+日K线量起爆更好+估换手小于10%时更稳定'),COLORGREEN;};DRAWTEXT(突破,最低+轴差*0.50,'分时突破'),COLORWHITE;DRAWNUMBER(突破,最低+轴差*0.40,首次突破价),COLORWHITE;DRAWTEXT(CROSS(EXPMA((DCLOSE/VBNH),60),EXPMA((DCLOSE/VBNH),120)),最低+轴差*0.35,'★迹'),COLORYELLOW;{DRAWICON(CROSS(EXPMA((DCLOSE/VBNH),20),1.01),MAX(资金流量,攻击流量),18);} DRAWTEXT(FILTER(BARSLAST(C<MIN(MMA30,强弱界定))<=20 AND CROSS(C,MAX(MMA30,强弱界定)),30),最低+轴差*0.2,'关注'),COLORRED;。

20个极品通达信指标公式源码

20个极品通达信指标公式源码

公式1(未来函数)代码N1:=5;N2:=10;N3:=20;N4:=30;P:=2;M:=20;N:=250;M1:=55;W:=21;P3:=500;N9:=90; HR:=HHV(HIGH,M1);HRY:=LLV(LOW,M1);HRY11:=HR*HRY;HRY33:SQRT(HRY11),COLORGREEN,LINETHICK2;IF(C>HRY33 AND HRY33 >=REF(HRY33 ,1), HRY33 ,DRAWNULL),LINETHICK2,COLORRED; MA1:EMA(CLOSE,N1);MA2:EMA(CLOSE,N2);MA3:EMA(CLOSE,N3),COLOR00FFFF;MA4:EMA(CLOSE,N4),LINETHICK2;TJ1:=CROSS(MA1,MA2) AND C>O AND C>REF(C,1) AND C/REF(C,1)>=1.018OR CROSS(MA1,MA4) AND C>O AND C>REF(C,1) AND C/REF(C,1)>=1.018OR CROSS(MA2,MA3) AND C>O AND C>REF(C,1) AND C/REF(C,1)>=1.018OR CROSS(MA1,MA3) AND C>O AND C>REF(C,1) AND C/REF(C,1)>=1.018;TJ2:=(MAX(MA1,MAX(MA2,MA3))-MIN(MA1,MIN(MA2,MA3)))/MIN(MA1,MIN(MA2,MA3))*100<=P;XG:=TJ1 AND TJ2;RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;K:=SMA(RSV,3,1);D:=SMA(K,3,1);DIFF:= EMA(CLOSE,12) - EMA(CLOSE,26);DEA :=EMA(DIFF,9);MACD:=2*(DIFF-DEA);做多:=IF(K>D AND MACD>0 AND V>1,2,0),COLORRED;做空:=IF(K<D AND MACD<0 AND V>1,-2,0),COLOR00FF00;强洗:=IF(MACD>0 AND K<D AND V>1,1,0),COLOR0099FF;弱升:=IF(MACD<0 AND K>D AND V>1,-1,0),COLORFFFF00;STICKLINE(做多AND C>=O,C,O,3,1),COLORRED;STICKLINE(做多AND C<O,C,O,3,0),COLOR990099;STICKLINE(做多AND C<O,C,O,1,0),COLORCC00CC;STICKLINE(做多AND C<O,C,O,0.3,0),COLORFF00FF;STICKLINE(做多AND C>=O,C,O,3,1),COLOR0000FF;{STICKLINE(做多AND C>=O,C,O,1.5,0),COLOR0000DD;STICKLINE(做多AND C>=O,C,O,0.4,0),COLOR0000FF;}STICKLINE(做空AND C>=O,L,H,0.1,0),COLOR0000FF;STICKLINE(做空AND C>=O,C,O,3,1),COLOR00FF00;{STICKLINE(做空AND C<O,C,O,3,0),COLOR00FF00;STICKLINE(做空AND C<O,C,O,0.3,0),COLOR00FF00;STICKLINE(做空AND C<O,C,O,0.3,0),COLOR00FF00;}STICKLINE(强洗AND C>=O,L,H,0.1,0),COLOR0000FF;STICKLINE(强洗AND C>=O,C,O,3,1),COLORFFFFFF;STICKLINE(强洗AND C<O,C,O,3,0),COLOR999999;STICKLINE(强洗AND C<O,C,O,1,0),COLORCCCCCC;STICKLINE(强洗AND C<O,C,O,0.3,0),COLORFFFFFF;STICKLINE(弱升AND C>=O,C,O,3,1),COLOR00FFFF;STICKLINE(弱升AND C<O,C,O,3,0),COLOR009999;STICKLINE(弱升AND C<O,C,O,0.3,0),COLOR00FFFF;STICKLINE(FILTER(TJ1,3),C,O,4,0),COLOR0000FF;DRAWICON(FILTER(XG,3),L*0.985,23);GET:=ZIG(3,3),COLORYELLOW;PL5:=ZIG(3,5);EN1:=ZIG(3,5)>REF(ZIG(3,5),1) AND REF(ZIG(3,5),1)<=REF(ZIG(3,5),2) AND REF(ZIG(3,5),2)<=REF(ZIG(3,5),3);EX1:=ZIG(3,5)<REF(ZIG(3,5),1) AND REF(ZIG(3,5),1)>=REF(ZIG(3,5),2) AND REF(ZIG(3,5),2)>=REF(ZIG(3,5),3);PL10:=ZIG(3,10);EN2:=ZIG(3,10)>REF(ZIG(3,10),1) AND REF(ZIG(3,10),1)<=REF(ZIG(3,10),2) AND REF(ZIG(3,10),2)<=REF(ZIG(3,10),3);EX2:=ZIG(3,10)<REF(ZIG(3,10),1) AND REF(ZIG(3,10),1)>=REF(ZIG(3,10),2) AND REF(ZIG(3,10),2)>=REF(ZIG(3,10),3);PL20:=ZIG(3,20);EN3:=ZIG(3,20)>REF(ZIG(3,20),1) AND REF(ZIG(3,20),1)<=REF(ZIG(3,20),2) AND REF(ZIG(3,20),2)<=REF(ZIG(3,20),3);EX3:=ZIG(3,20)<REF(ZIG(3,20),1) AND REF(ZIG(3,20),1)>=REF(ZIG(3,20),2) AND REF(ZIG(3,20),2)>=REF(ZIG(3,20),3);PL40:=ZIG(3,40);走强1:=BARSLAST(PL5<REF(PL5,1));走弱1:=BARSLAST(PL5>REF(PL5,1));走强2:=BARSLAST(PL10<REF(PL10,1));走弱2:=BARSLAST(PL10>REF(PL10,1));走强3:=BARSLAST(PL20<REF(PL20,1));走弱3:=BARSLAST(PL20>REF(PL20,1));ZTJZ5:=IF(PL10>REF(PL10,1),COUNT(EN1,走强2),0);ZTJD5:=IF(PL10>REF(PL10,1),COUNT(EX1,走强2),0);DTJZ5:=IF(PL10<REF(PL10,1),COUNT(EN1,走弱2),0);DTJD5:=IF(PL10<REF(PL10,1),COUNT(EX1,走弱2),0);ZTJZ10:=IF(PL20>REF(PL20,1),COUNT(EN2,走强3),0);ZTJD10:=IF(PL20>REF(PL20,1),COUNT(EX2,走强3),0);DTJZ10:=IF(PL20<REF(PL20,1),COUNT(EN2,走弱3),0);DTJD10:=IF(PL20<REF(PL20,1),COUNT(EX2,走弱3),0);DRAWTEXT(EN1 AND DTJZ5=1,L*0.98,'(A)'),COLORFFFF00;DRAWTEXT(EX1 AND DTJD5=2,H*1.02,'(B)'),COLORFF00FF;DRAWTEXT(EN2 AND ZTJZ5=1,L*0.98,'(C)'),COLOR0000FF;DRAWTEXT(EN2 AND DTJZ10=1,L*0.93,'Ⅰ'),COLORFF00FF;DRAWTEXT(EX2 AND DTJD10=2,H*1.05,'Ⅱ'),COLORFFFF00;DRAWTEXT(EN3 AND ZTJZ10=1,L*0.93,'Ⅲ'),COLOR0000FF;DRAWTEXT(EX2 AND PL20>REF(PL20,1) AND ZTJD10=1,H*1.03,'①'),LINETHICK3,COLOR00FFFF; DRAWTEXT(EN2 AND PL20>REF(PL20,1) AND ZTJZ10=2,L*0.95,'②'),LINETHICK3,COLOR00FFFF; DRAWTEXT(EX2 AND PL20>REF(PL20,1) AND ZTJD10=2 OR (ZTJD10=0 OR ZTJD10=2)AND EX2,H*1.03,'③'),LINETHICK3,COLOR00FFFF;DRAWTEXT(EN2 AND PL20>REF(PL20,1) AND ZTJZ10=3,L*0.95,'④'),LINETHICK3,COLOR00FFFF;TJ11:=EN2 AND ZTJZ5=1;TJ22:=EN1 AND PL10>REF(PL10,1) AND ZTJZ5=2;TJ33:=EN2 AND DTJZ10=1;TJ44:=EN3 AND ZTJZ10=1;TJ55:=EN2 AND PL20>REF(PL20,1) AND ZTJZ10=2;XG22:=TJ11 OR TJ22 OR TJ33 OR TJ44 OR TJ55;MM:=C>HRY33 AND HRY33 >=REF(HRY33 ,1);QQ:=HRY33>=REF(HRY33 ,1);XG11:=CROSS(C,HRY33) AND QQ AND MM;BUY1:=LAST(CLOSE>MA(CLOSE,55),0,5);BUY2:=EXIST(CLOSE<MA(CLOSE,55),5);BUY:=CLOSE>MA(CLOSE,55)&&BUY1&&BUY2;W18:=FILTER(EXIST(XG11 OR BUY,1),5);STICKLINE(W18,C,(C+O)/2,4,0),COLORFF00FF;DRAWTEXT(W18,L*0.97,'牛'),COLOR00FFFF;X1:=REF(C,1)/HHV(H,20)<0.82;X2:=(MIN(C,O)-L)/(H-L)>0.67;X3:=(HIGH-MAX(CLOSE,OPEN))/(HIGH-LOW)<0.33;X4:=ABS(C-O)/C<0.01;DOWN:=O>C;X5:=COUNT(DOWN,7)>=5;XG8:=X1 AND X2 AND X3 AND X4 AND X5;DRAWTEXT(XG8,L*0.98,'螺'),COLOR00FFFF;AA:=REF(C,1)/REF(O,1)<0.96;BB:=C/O>1.03;CC:=C>REF(O,1);TJ81:=AA AND BB AND CC;X81:=REF(C,1)/HHV(H,20)<0.82;DN:=O>C;X82:=COUNT(DN,7)>=5;X83:=C=HHV(C,3);XG81:=TJ81 AND X81 AND X82;XG82:=X81 AND X82 AND X83;XG88:=XG81 OR XG82;DRAWTEXT(XG88,L*0.96,'反'),COLOR00FFFF;X01:=REF(C,1)/HHV(H,21)<0.77;{DOWN1:=O>C;X02:=COUNT(DOWN1,9)>=6;}X03:=ABS(C-O)/C<0.008;X04:=(H-L)/C>0.025;XG0:=X01 AND X03 AND X04;DRAWTEXT(XG0,L*0.97,'星'),COLOR00FFFF;S1:=REF(C,1)/LLV(L,W)>1.30;S2:=(H-MAX(C,O))/(H-L)>0.60;S3:=ABS(C-O)/C<0.03;S4:=(H-O)/C>0.05 AND C<O;SAL1:=S1 AND S2 AND S3;SAL2:=S1 AND ABS(C-O)/C>0.05 AND C<O;SAL3:=S1 AND ABS(C-O)/C<0.001;SAL4:=S1 AND S4;SAL5:=(H-MAX(C,O))/(H-L)>0.67 AND C<O AND S3;SAL:=SAL1 OR SAL2 OR SAL3 OR SAL4 OR SAL5;LC:=REF(CLOSE,1);RSI:=SMA(MAX(CLOSE-LC,0),4.1,1)/SMA(ABS(CLOSE-LC),4.1,1)*100;黄买:=FILTER((REF(CLOSE,2)<CLOSE AND RSI<25),7);黄卖:=FILTER((REF(CLOSE,2)>CLOSE AND RSI>80),7);红买:=FILTER(CROSS(RSI,11),7);红卖:=FILTER(CROSS(89,RSI),7);绿买:=FILTER(CROSS(RSI,20),7);绿卖:=FILTER(CROSS(80,RSI),7);SL1:=红卖AND 绿卖;SL2:=红卖AND 绿卖AND 黄卖;BU:=红买AND 绿买;SS1:=CROSS(MA(C,5),C);SS2:=(REF(C,1)-C)/REF(C,1)>0.04;SS3:=O<REF(C,1);JJ1:=SS1 AND SS2 AND SS3;SSL:=JJ1 AND S1;SAL8:=FILTER(SAL OR SSL,5);DRAWTEXT(SAL8 OR SL1 OR SL2,H*1.02,'卖'),COLOR00FF00; STICKLINE(SAL8 OR SL1 OR SL2,C,O,1,0),COLORFF0000; DRAWTEXT(SAL8 AND SL1 AND SL2,H*1.02,'必卖'),COLOR00FF00; MA20:=MA(CLOSE,20);AA10:=MA(CLOSE,8);中期大底:=LLV(LOW,30);支撑:=HHV(EMA(((((OPEN + LOW) + HIGH) + CLOSE) / 4),5),60);压力一:=HHV(LOW,20);中线:=MA(CLOSE,3);天:=(MA(LOW,15) * 0.985);人:=(MA(LOW,15) * 0.96);地:=(((HIGH + LOW) + CLOSE) / 3);B1:=HHV(地,(4 * 15));B6:=LLV(地,(4 * 15));B7:=(B1 - B6);B8:=(MA(((地- B6) / B7),2) * 80);短期底部:=(LLV(HIGH,30) * 0.93);MA80:=LLV(HIGH,30);压力二:=(SMA(HIGH,21,2) * 1.035);下档线:=(((CLOSE - LLV(LOW,13)) / (HHV(HIGH,13) - LLV(LOW,13))) * 100); RSV8:=SMA(下档线,3,1);K8:=SMA(RSV8,3,1);D8:=((3 * RSV8) - (2 * K8));J12:=(((CLOSE - LLV(LOW,55)) / (HHV(HIGH,55) - LLV(LOW,55))) * 100);K24:=SMA(SMA(J12,3,1),3,1);D24:=((3 * SMA(J12,3,1)) - (2 * K24));压力位:=IF(CROSS(D24,D),HIGH,L);长期底部:=LLV(HIGH,30);X18:=EMA((((((3 * CLOSE) + HIGH) + LOW) + OPEN) / 6),10);逃遁:=(SMA(HIGH,21,2) * 1.05);TJ18:=FILTER(((((LLV(LOW,0) AND ((MA(CLOSE,37) - REF(MA(CLOSE,37),1)) > 0)) AND (LOW <= 短期底部)) AND (WINNER(CLOSE) < 0.05)) AND ((CLOSE / OPEN)> 0.13)),7);图公式2代码PJJ:=DMA((H + L + C * 2) / 4,0.9);JJ:=REF(EMA(PJJ,3),1);QJJ:=VOL / ((H - L) * 2 - ABS(C - O));XVL:=IF(C > O,QJJ * (H - L),IF(C < O,QJJ * (H - O + (C - L)),VOL / 2))+ IF(C > O,0 - QJJ * (H - C + (O - L)),IF(C < O,0 - QJJ * (H - L),0 - VOL / 2)); HSL:=XVL / 20 / 1.15;攻击流量:=HSL * 0.55 + REF(HSL,1) * 0.33 + REF(HSL,2) * 0.22;GJJ:=EMA(攻击流量,2);DIFF:=(EMA(GJJ,12)-EMA(GJJ,26)),COLORGREEN;DEA:=MA(DIFF,2),COLORYELLOW;VA2:=LLV(LOW,33);VA3:=HHV(HIGH,21);VA4:=EMA((CLOSE-VA2)/(VA3-VA2)*100,10)*-1+100;趋势:=100-EMA(0.191*REF(VA4,1)+0.809*VA4,1);趋势线:=100-EMA(0.191*REF(VA4,1)+0.809*VA4,1);STICKLINE(DIFF>DEA AND 趋势线>REF(趋势线,1),HHV(H,5)*1.05,LLV(L,5)*0.95,4,0),COLOR781836;DRAWKLINE(H,O,L,C);V1:=ABS((2*CLOSE+HIGH+LOW)/4-MA(CLOSE,20))/MA(CLOSE,20);V2:=(1-7/100)*(DMA(CLOSE,V1));V3:=(1+7/100)*(DMA(CLOSE,V1));V5:=MA((LOW+HIGH+CLOSE)/3,5);支撑:REFDATE(V2,DATE),POINTDOT,LINETHICK3,COLORCC66FF;阻力:REFDATE(V3,DATE),POINTDOT,LINETHICK3,COLORGREEN;VAR1:=CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2);VAR2:=REF(VAR1,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);VAR3:=REF(VAR2,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);VAR4:=REF(VAR3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);VAR5:=REF(VAR4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);VAR6:=REF(VAR5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);VAR7:=REF(VAR6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);VAR8:=REF(VAR7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);VAR9:=REF(VAR8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VARA:=REF(VAR9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VARB:=REF(VARA,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VARC:=REF(VARB,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VARD:=CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2);VARE:=REF(VARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VARF:=REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);VAR10:=REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);VAR11:=REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VAR12:=REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VAR13:=REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VAR14:=REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VAR15:=REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VAR16:=REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VAR17:=REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VAR18:=REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VAR19:=REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1) AND VAR1;STICKLINE(VAR19,L,L*0.98,3,0),COLORYELLOW;VAR1A:=REF(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,1) AND VARD;STICKLINE(VAR1A,H*1.01,H,3,0),COLOR00FF00{98FD};MA3:MA(C,3);MA5:MA(C,5),COLORWHITE;MA10:=MA(C,10),NODRAW;MA30:MA(C,34),NODRAW;五日乖离率:=(C-MA5)/MA5*100;BB5:=ATAN((MA5/REF(MA5,1)-1)*100)*180/3.1416;IF(BB5>30 AND MA5>REF(MA5,1), MA5,DRAWNULL),LINETHICK1,COLORRED;BB10:=ATAN((MA10/REF(MA10,1)-1)*100)*180/3.1416;IF(BB5<0 AND MA5<REF(MA5,1), MA5,DRAWNULL),LINETHICK1,COLORGREEN;DD5:=MA5<REF(MA5,1);IF(DD5,MA5,DRAWNULL),COLOR00FF00;X0:=(3*C+L+O+H)/6;多空线: (20*X0+19*REF(X0,1)+18*REF(X0,2)+17*REF(X0,3)+16*REF(X0,4)+15*REF(X0,5)+14*REF(X0,6)+13*REF(X0,7)+12*REF(X0,8)+11*REF(X0,9)+10*REF(X0,10)+9*REF(X0,11)+8*REF(X0,12)+7*REF(X0,13)+6*REF(X0,14)+5*REF(X0,15)+4*REF(X0,16)+3*REF(X0,17)+2*REF(X0,18)+REF(X0,20))/210,COLORFF00FF,LINETHICK1;{用法:黄托底买进,绿压顶买出。

  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

思路要点:
1、股价回落到至5日线均和10日均线之间时,两均线仍保持向上运行;
2、股价回落时,成交量处在缩量状态;
3、股价首次回落至两均线夹角处时,预警信号4个点以下。

{主图}
M5:MA(C,5);
M10:MA(C,10);
TJ1:=EVERY(V<REF(V,3),2)AND MIN(C,O)<REF(MIN(C,O),1)OR L<REF(L,1); GL:=(M5/M10-1)*100;
TJ2:=EVERY(GL<18 AND M5>M10 AND M10>=REF(M10,1),3);
TJ3:=(RANGE(REF(C,1),REF(M10,1),REF(M5,1)) OR
RANGE(REF(O,1),REF(M10,1),REF(M5,1))) ;
XG:=REF(TJ1,1) AND TJ3 AND TJ2 AND CROSS(C+0.01>=M5,0.5); DRAWICON(XG,L*0.95,1);
STICKLINE(XG,C,O,2,0),COLORYELLOW;
STICKLINE(XG,H,L,0,0),COLORYELLOW;
{幅图}
M5:=MA(C,5);
M10:=MA(C,10);
TJ1:=EVERY(V<REF(V,3),2)AND MIN(C,O)<REF(MIN(C,O),1)OR L<REF(L,1); GL:=(M5/M10-1)*100;
TJ2:=EVERY(GL<18 AND M5>M10 AND M10>=REF(M10,1),3);
TJ3:=(RANGE(REF(C,1),REF(M10,1),REF(M5,1)) OR
RANGE(REF(O,1),REF(M10,1),REF(M5,1))) ;
XG:=REF(TJ1,1) AND TJ3 AND TJ2 AND CROSS(C+0.01>=M5,0.5); STICKLINE(XG,0,7,1.5,0),COLORYELLOW;
{选股}
M5:=MA(C,5);
M10:=MA(C,10);
TJ1:=EVERY(V<REF(V,3),2)AND MIN(C,O)<REF(MIN(C,O),1)OR L<REF(L,1); GL:=(M5/M10-1)*100;
TJ2:=EVERY(GL<18 AND M5>M10 AND M10>=REF(M10,1),3);
TJ3:=(RANGE(REF(C,1),REF(M10,1),REF(M5,1)) OR
RANGE(REF(O,1),REF(M10,1),REF(M5,1))) ;
XG:REF(TJ1,1) AND TJ3 AND TJ2 AND CROSS(C+0.01>=M5,0.5);。

相关文档
最新文档