通达信 指标公式源码大全借鉴.pdf
《通达信 指标公式源码大全借鉴.pdf》由会员分享,可在线阅读,更多相关《通达信 指标公式源码大全借鉴.pdf(44页珍藏版)》请在淘文阁 - 分享文档赚钱的网站上搜索。
1、公式 1(未来函数)代码公式 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(CHRY33 AND HRY33=REF(HRY33,1),HRY33,DRAWNULL),LINETHICK2,COLORRED;MA1:EMA(CLOSE,N1);MA2:EMA(CLOSE,N2);MA3:EMA(CL
2、OSE,N3),COLOR00FFFF;MA4:EMA(CLOSE,N4),LINETHICK2;TJ1:=CROSS(MA1,MA2)AND CO AND CREF(C,1)AND C/REF(C,1)=1.018OR CROSS(MA1,MA4)AND CO AND CREF(C,1)AND C/REF(C,1)=1.018OR CROSS(MA2,MA3)AND CO AND CREF(C,1)AND C/REF(C,1)=1.018OR CROSS(MA1,MA3)AND CO AND CREF(C,1)AND C/REF(C,1)=1.018;TJ2:=(MAX(MA1,MAX(MA
3、2,MA3)-MIN(MA1,MIN(MA2,MA3)/MIN(MA1,MIN(MA2,MA3)*100D AND MACD0 AND V1,2,0),COLORRED;做空:=IF(KD AND MACD1,-2,0),COLOR00FF00;强洗:=IF(MACD0 AND K1,1,0),COLOR0099FF;弱升:=IF(MACDD AND V1,-1,0),COLORFFFF00;STICKLINE(做多 AND C=O,C,O,3,1),COLORRED;STICKLINE(做多 AND CO,C,O,3,0),COLOR990099;STICKLINE(做多 AND CO,C,
4、O,1,0),COLORCC00CC;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 CO,C,O,3,0),COLOR00FF00;STICKLINE(做空 AND CO,C,O,
5、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 CO,C,O,3,0),COLOR999999;STICKLINE(强洗 AND CO,C,O,1,0),COLORCCCCCC;STICKLINE(强洗 AND C=O,C,O,3,1),COLOR00FFFF;STICKLINE(弱升 AND CO,C,O,3,0),COLOR009999;STICKL
6、INE(弱升 AND CREF(ZIG(3,5),1)ANDREF(ZIG(3,5),1)=REF(ZIG(3,5),2)REF(ZIG(3,5),2)=REF(ZIG(3,5),3);EX1:=ZIG(3,5)=REF(ZIG(3,5),2)REF(ZIG(3,5),2)=REF(ZIG(3,5),3);PL10:=ZIG(3,10);EN2:=ZIG(3,10)REF(ZIG(3,10),1)ANDREF(ZIG(3,10),1)=REF(ZIG(3,10),2)REF(ZIG(3,10),2)=REF(ZIG(3,10),3);EX2:=ZIG(3,10)=REF(ZIG(3,10),2
7、)REF(ZIG(3,10),2)=REF(ZIG(3,10),3);PL20:=ZIG(3,20);EN3:=ZIG(3,20)REF(ZIG(3,20),1)ANDREF(ZIG(3,20),1)=REF(ZIG(3,20),2)REF(ZIG(3,20),2)=REF(ZIG(3,20),3);EX3:=ZIG(3,20)=REF(ZIG(3,20),2)REF(ZIG(3,20),2)=REF(ZIG(3,20),3);PL40:=ZIG(3,40);走强 1:=BARSLAST(PL5REF(PL5,1);走强 2:=BARSLAST(PL10REF(PL10,1);走强 3:=BA
8、RSLAST(PL20REF(PL20,1);ZTJZ5:=IF(PL10REF(PL10,1),COUNT(EN1,走强 2),0);ZTJD5:=IF(PL10REF(PL10,1),COUNT(EX1,走强 2),0);DTJZ5:=IF(PL10REF(PL10,1),COUNT(EN1,走弱 2),0);DTJD5:=IF(PL10REF(PL20,1),COUNT(EN2,走强 3),0);ZTJD10:=IF(PL20REF(PL20,1),COUNT(EX2,走强 3),0);DTJZ10:=IF(PL20REF(PL20,1),COUNT(EN2,走弱 3),0);DTJD1
9、0:=IF(PL20REF(PL20,1)AND ZTJD10=1,H*1.03,),LINETHICK3,COLOR00FFFF;DRAWTEXT(EN2 AND PL20REF(PL20,1)AND ZTJZ10=2,L*0.95,),LINETHICK3,COLOR00FFFF;DRAWTEXT(EX2 AND PL20REF(PL20,1)AND ZTJD10=2 OR(ZTJD10=0 OR ZTJD10=2)AND EX2,H*1.03,),LINETHICK3,COLOR00FFFF;DRAWTEXT(EN2 AND PL20REF(PL20,1)AND ZTJZ10=3,L*0
10、.95,),LINETHICK3,COLOR00FFFF;TJ11:=EN2 AND ZTJZ5=1;TJ22:=EN1 AND PL10REF(PL10,1)AND ZTJZ5=2;TJ33:=EN2 AND DTJZ10=1;TJ44:=EN3 AND ZTJZ10=1;TJ55:=EN2 AND PL20REF(PL20,1)AND ZTJZ10=2;XG22:=TJ11 OR TJ22 OR TJ33 OR TJ44 OR TJ55;MM:=CHRY33 AND HRY33=REF(HRY33,1);QQ:=HRY33=REF(HRY33,1);XG11:=CROSS(C,HRY33)
11、AND QQ AND MM;BUY1:=LAST(CLOSEMA(CLOSE,55),0,5);BUY2:=EXIST(CLOSEMA(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.67;X3:=(HIGH-MAX(CLOSE,OPEN)/(HIGH-LOW)0.33;X4:=ABS(C-O)/CC;X5:=COUNT(DOWN,7
12、)=5;XG8:=X1 AND X2 AND X3 AND X4 AND X5;DRAWTEXT(XG8,L*0.98,螺),COLOR00FFFF;AA:=REF(C,1)/REF(O,1)1.03;CC:=CREF(O,1);TJ81:=AA AND BB AND CC;X81:=REF(C,1)/HHV(H,20)C;X82:=COUNT(DN,7)=5;X83:=C=HHV(C,3);XG81:=TJ81 ANDX81 AND X82;XG82:=X81 AND X82 AND X83;XG88:=XG81 OR XG82;DRAWTEXT(XG88,L*0.96,反),COLOR00
13、FFFF;X01:=REF(C,1)/HHV(H,21)C;X02:=COUNT(DOWN1,9)=6;X03:=ABS(C-O)/C0.025;XG0:=X01AND 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)/C0.05 AND C0.05 AND CO;SAL3:=S1 AND ABS(C-O)/C0.67 AND CO AND S3;SAL:=SAL1 OR SAL2 OR SAL3 OR SAL4 OR S
14、AL5;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 RSICLOSE AND RSI80),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 绿买
15、;SS1:=CROSS(MA(C,5),C);SS2:=(REF(C,1)-C)/REF(C,1)0.04;SS3:=O 0)AND(LOW=短期底部)AND(WINNER(CLOSE)0.13),7);图图公式公式 2 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,0-QJJ*(H-C+(O-L),IF(C DEA AND 趋势线REF(趋势线,1),HHV(H,5)*1.05,LLV(L,5)*0.95,4,0),COLOR
16、781836;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:=CLOSEREF(CLOSE,1)AND CLOS
17、EREF(CLOSE,2);VAR2:=REF(VAR1,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,2);VAR5:=REF(VAR4,1)AND CLOSE=REF(CLOSE,1)AND CLOSE=REF(CLOSE,2);VAR6:=REF(VAR5,1)AND CLOSE=REF(CLOSE,2);VAR7:=REF(VAR6,1)AND CLOSE=REF(CLOSE,1)AND
18、 CLOSE=REF(CLOSE,2);VAR8:=REF(VAR7,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,2);VARB:=REF(VARA,1)AND CLOSE=REF(CLOSE,1)AND CLOSE=REF(CLOSE,2);VARC:=REF(VARB,1)AND CLOSE=REF(CLOSE,2);VARD:=CLOSEREF(CLOSE,1)AND CLOSE=REF
19、(CLOSE,1)AND CLOSE=REF(CLOSE,2);VARF:=REF(VARE,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,2);VAR12:=REF(VAR11,1)AND CLOSE=REF(CLOSE,1)AND CLOSE=REF(CLOSE,2);VAR13:=REF(VAR12,1)AND CLOSE=REF(CLOSE,2);VAR14:=REF(VAR13,
20、1)AND CLOSE=REF(CLOSE,1)AND CLOSE=REF(CLOSE,2);VAR15:=REF(VAR14,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,2);VAR18:=REF(VAR17,1)AND CLOSE=REF(CLOSE,1)AND CLOSE30 AND MA5REF(MA5,1),MA5,DRAWNULL),LINETHICK1,COLORRED;
21、BB10:=ATAN(MA10/REF(MA10,1)-1)*100)*180/3.1416;IF(BB50 AND MA5REF(MA5,1),MA5,DRAWNULL),LINETHICK1,COLORGREEN;DD5:=MA5REF(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
22、(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;用法:黄托底买进,绿压顶买出。DD:=多空线多空线);IF(A,多空线,DRAWNULL),COLORYELLOW,POINTDOT;A1:=(MA5多空线);IF(A1,多空线,DRAWNULL),COLORWHITE;A2:=3*EMA(C-LLV(L,30)/(HHV
23、(H,30)-LLV(L,30)*100,5)-2*EMA(C-LLV(L,30)/(HHV(H,30)-LLV(L,30)*100,5);A4:=(HHV(H,34)-C)/(HHV(H,34)-LLV(L,34)*100;A5:=EMA(CLOSE,12)-EMA(CLOSE,26);A6:=EMA(A5,9);A7:=(A5A6);财神:IF(A7,LLV(L,21),DRAWNULL)COLORRED,CIRCLEDOT;CYS:=(EMA(CLOSE-V2)/V2,1)*100);AA0:=CYS;MIDD:=MA(CYS,20);CC0:=MIDD+0.85*STD(CYS,10)
24、;TM6:=AA0CC0;IF(TM6,MA5,DRAWNULL),COLORRED,LINETHICK1;A0:=(L+H+C*2)/4;工作:=EMA(A0,14)COLORYELLOW,LINETHICK1;度假:=EMA(A0,25)COLORYELLOW,LINETHICK1;A1X:=(工作-REF(工作,1)/REF(工作,1)*100;A2X:=(度假-REF(度假,1)/REF(度假,1)*100;G:=BARSLAST(CROSS(A1X,0);KDJRSV:=(CLOSE-LLV(LOW,9)/(HHV(HIGH,9)-LLV(LOW,9)*100;K:=SMA(RSV,
25、3,1);D:=SMA(K,3,1);J:=3*K-2*D;金叉:=CROSS(J,D);死叉:=CROSS(D,J);买 1:=(VAR14 OR VAR15)AND VAR11;买 2:=(VAR14 OR VAR15)AND VAR4;买 3:=(VAR14 OR VAR15)AND VAR2;买 4:=(VAR2 AND VAR11)OR(VAR4 AND VAR11);买 5:=(金叉 AND VAR4)OR(金叉 AND VAR2)OR(金叉 AND VAR11);涨停STICKLINE(CLOSEREF(CLOSE,1)*1.0985 AND CLOSE=HIGH,CLOSE,O
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 通达信 指标公式源码大全借鉴 指标 公式 源码 大全 借鉴
限制150内