1、波浪理论画线 升级版 通达信版本的波浪理论画线指标,特此奉上,我也是股友给的,然后经过一些修改调整。 源码如下图: N:=20;P:=8; GJ:=(C+H+L+O)/4;阻:=L+(GJ-L)+(C-L);支:=L+(C-GJ); 压力:REF(阻 , 1),NODRAW,COLOR00FF00; 支撑:REF(支 , 1),NODRAW,COLORYELLOW; STICKLINE(ISLASTBAR,压力,压力,30,1),LINETHICK1,COLOR00FF00; STICKLINE(ISLASTBAR,支撑,支撑,30,1),LINETHICK1,COLORYELLOW; 下档线:=(((CLOSE - LLV(LOW,13)) / (HHV(HIGH,13) - LLV(LOW,13))) * 100); RRRSV:=SMA(下档线,3,1);KKK:=SMA(RRRSV,3,1);DDD:=((3 * RRRSV) - (2 * KKK)); JJ12:=(((CLOSE - LLV(LOW,55)) / (HHV(HIGH,55) - LLV(LOW,55))) * 100); RSV24:=SMA(JJ12,3,1);K24:=SMA(RSV24,3,1);D24:=((3 * RSV24) - (2 * K24)); 顶部:=IF(CROSS(D24,DDD),HIGH,REF(HIGH,BARSLAST(CROSS(D24,DDD)))),COLORFFFFFF; 决策:IF(ISLASTBAR,顶部,DRAWNULL),COLORMAGENTA; STICKLINE(ISLASTBAR ,决策,决策,60,1),LINETHICK2,COLORMAGENTA; 底部:=LLV(HIGH,30),COLOR00FF00; 超跌:IF(ISLASTBAR,底部,DRAWNULL),COLORRED; STICKLINE(ISLASTBAR ,超跌,超跌,60,1),LINETHICK2,COLORRED; 风险参数:MA((MA(C,13)-MA(C,55))/MA(C,13)*100,1),NODRAW,COLORFFFF00; 波:=ZIG(3,P),COLORWHITE; 涨天:BARSLASTCOUNT(波>REF(波,1)),NODRAW,COLORRED; VAR1:=(C-REF(C,涨天))/REF(C,涨天)*100; 涨幅%:IF(涨天>0,VAR1, DRAWNULL),NODRAW; 跌天:BARSLASTCOUNT(波<REF(波,1)),NODRAW,COLOR00FF00; VAR2:=(C-REF(C,跌天))/REF(C,跌天)*100; 跌幅%:IF(跌天>0,VAR2, DRAWNULL),NODRAW; {红} {STICKLINE(C>O,C,O,3,0),COLOR000077; STICKLINE(C>O,C,O,2,0),COLOR000099; STICKLINE(C>O,C,O,1,0),COLOR0000BB; STICKLINE(C>O,H,L,0,0),COLOR0000FF;} {绿} {STICKLINE(C<O,C,O,3,0),COLOR007700; STICKLINE(C<O,C,O,2,0),COLOR009900; STICKLINE(C<O,C,O,1,0),COLOR00BB00; STICKLINE(C<O,H,L,0,0),COLOR00FF00;} {浪} {浪线6:DRAWLINE(H=HHV(H,6),H,L=LLV(L,6),L,0),LINETHICK2,COLORRED; 浪线6X:DRAWLINE(L=LLV(L,6),L,H=HHV(H,6),H,0),LINETHICK2,COLORRED;} 浪线7:DRAWLINE(H=HHV(H,7),H,L=LLV(L,7),L,0),LINETHICK1,COLORYELLOW; 浪线7X:DRAWLINE(L=LLV(L,7),L,H=HHV(H,7),H,0),LINETHICK1,COLORYELLOW; {浪线21:DRAWLINE(H=HHV(H,21),H,L=LLV(L,21),L,0),LINETHICK2,COLORFF7F00; 浪线21X:DRAWLINE(L=LLV(L,21),L,H=HHV(H,21),H,0),LINETHICK2,COLORFF7F00;} 浪线35:DRAWLINE(H=HHV(H,35),H,L=LLV(L,35),L,0),LINETHICK1,COLORMAGENTA; 浪线35X:DRAWLINE(L=LLV(L,35),L,H=HHV(H,35),H,0),LINETHICK1,COLORMAGENTA; {浪线49:DRAWLINE(H=HHV(H,49),H,L=LLV(L,49),L,0),LINETHICK2,COLORGREEN; 浪线49X:DRAWLINE(L=LLV(L,49),L,H=HHV(H,49),H,0),LINETHICK2,COLORGREEN; }; {趋势} A1:=REF(H,N)=HHV(H,2*N+1); B1:=FILTER(A1,N); C1:=BACKSET(B1,N+1); D1:=FILTER(C1,N); R11:=BACKSET(ISLASTBAR,BARSLAST(D1)+1); S11:=R11>REF(R11,1); DRAWLINE(D1,H,S11,H,1),COLORGREEN,CROSSDOT; A2:=REF(L,N)=LLV(L,2*N+1); B2:=FILTER(A2,N); C2:=BACKSET(B2,N+1); D2:=FILTER(C2,N); T11:=BACKSET(ISLASTBAR,BARSLAST(D2)+1); U11:=T11>REF(T11,1); DRAWLINE(D2,L,U11,L,1),COLORRED,CIRCLEDOT; M:=INTPART(3*N/5); A12:=REF(H,M)=HHV(H,2*M+1); B12:=FILTER(A12,M); C12:=BACKSET(B12,M+1); D12:=FILTER(C12,M); R112:=BACKSET(ISLASTBAR,BARSLAST(D12)+1); S112:=R112>REF(R112,1); DRAWLINE(D12,H,S112,H,1),COLORGREEN,POINTDOT; A22:=REF(L,M)=LLV(L,2*M+1); B22:=FILTER(A22,M); C22:=BACKSET(B22,M+1); D22:=FILTER(C22,M);{低点} T112:=BACKSET(ISLASTBAR,BARSLAST(D22)+1); U112:=T112>REF(T112,1); DRAWLINE(D22,L,U112,L,1),COLORRED,POINTDOT; AAA2:=SUM(IF( CLOSE>REF(CLOSE,1),VOL*C,0),0); AAA3:=SUM(IF( CLOSE<REF(CLOSE,1),VOL*C,0),0); AAA4:=SUM(IF( CLOSE=REF(CLOSE,1),VOL*C,0),0); BB1:=0; B1万元:=DVOL*DCLOSE/100; B1差:=B1万元-REF(B1万元,1); B2万元:=DVOL*DCLOSE/100; B2比:=B2万元/REF(B2万元,1); 净流入万元:=(AAA2-AAA3-0.5*AAA4); PM:=MA(净流入万元,1); PMA:=PM/REF(PM,1)>1; PMB:=REF(PMA,1)<1 AND PMA; 密码:(EMA(MA(B1万元,2),2))/100000,COLORYELLOW,NODRAW; 二日比:=密码/REF(密码,1); 选股:PMB AND 密码>REF(密码,1) AND 二日比>1,COLORRED,NODRAW; {MA5:MA(C,5);MA10:MA(C,10);MA30:MA(C,30);} DRAWNUMBER(选股=1 ,L,密码),COLORYELLOW; { DRAWICON(选股,L*0.975,1);} DRAWTEXT_FIX(ISLASTBAR,0.25,0.99,0,STRCAT(STRCAT(STRCAT(STRCAT(STRCAT(HYBLOCK,FGBLOCK),DYBLOCK),GNBLOCK),'股东数:'),CON2STR(FINANCE(8),0))),COLORYELLOW; 2、【牛魔王】( 顶尖财经 股票学院: http://www.58188.com ) YM:EMA(SLOPE((CLOSE+HIGH+LOW)/3,24)*20+(CLOSE+HIGH+LOW)/3,40),COLORRED,LINETHICK1; IF(EMA((CLOSE+HIGH+LOW)/3,3)>=YM,YM,DRAWNULL),DOTLINE,COLORRED; IF(EMA((CLOSE+HIGH+LOW)/3,3)<=YM,YM,DRAWNULL),DOTLINE,COLORGREEN; STICKLINE(EMA((CLOSE+HIGH+LOW)/3,3)>=YM,LOW,HIGH,0,0),COLORRED; STICKLINE(EMA((CLOSE+HIGH+LOW)/3,3)>=YM,CLOSE,OPEN,3,0),COLORRED; STICKLINE(EMA((CLOSE+HIGH+LOW)/3,3)<=YM,LOW,HIGH,0,0),COLORGREEN; STICKLINE(EMA((CLOSE+HIGH+LOW)/3,3)<=YM,CLOSE,OPEN,3,0),COLORGREEN; MACD价格1:=EMA(CLOSE,3) - EMA(CLOSE,9); DEA1021:=EMA((EMA(MACD价格1,102) - EMA(MACD价格1,204)),9); DEA511:=EMA((EMA(MACD价格1,51) - EMA(MACD价格1,102)),9); DEA36361:=EMA((EMA(MACD价格1,36) - EMA(MACD价格1,72)),9); DEA24241:=EMA((EMA(MACD价格1,24) - EMA(MACD价格1,48)),9); DEA18181:=EMA((EMA(MACD价格1,18) - EMA(MACD价格1,36)),9); DEA661:=EMA((EMA(MACD价格1,6) - EMA(MACD价格1,12)),9); DEA331:=EMA((EMA(MACD价格1,3) - EMA(MACD价格1,9)),9); DEA12121:=EMA((EMA(MACD价格1,12) - EMA(MACD价格1,24)),9); MACD24241:=2*((EMA(MACD价格1,24) - EMA(MACD价格1,48))-DEA24241); HH1:=(20*H+19*REF(H,1)+18*REF(H,2)+17*REF(H,3)+16*REF(H,4)+15*REF(H,5)+14*REF(H,6) +13*REF(H,7)+12*REF(H,8)+11*REF(H,9)+10*REF(H,10)+9*REF(H,11)+8*REF(H,12) +7*REF(H,13)+6*REF(H,14)+5*REF(H,15)+4*REF(H,16)+3*REF(H,17)+2*REF(H,18)+ REF(H,20))/210,COLORBLUE,LINETHICK1; LL1:=(20*L+19*REF(L,1)+18*REF(L,2)+17*REF(L,3)+16*REF(L,4)+15*REF(L,5)+14*REF(L,6) +13*REF(L,7)+12*REF(L,8)+11*REF(L,9)+10*REF(L,10)+9*REF(L,11)+8*REF(L,12) +7*REF(L,13)+6*REF(L,14)+5*REF(L,15)+4*REF(L,16)+3*REF(L,17)+2*REF(L,18)+ REF(L,20))/210,COLORBLUE,LINETHICK1; D90H1:=EMA(HH1,90),COLORRED,LINETHICK1; D90L1:=EMA(LL1,90),COLORRED,LINETHICK1; D901:=(D90H1+D90L1)/2; www70822com:=(D90H1+D90L1)/2; Y1M:=EMA(SLOPE((CLOSE+HIGH+LOW)/3,24)*20+(CLOSE+HIGH+LOW)/3,48); CCI151:=((HIGH+LOW+CLOSE)/3-MA((HIGH+LOW+CLOSE)/3,15))/(0.015*AVEDEV((HIGH+LOW+CLOSE)/3,15)); CCI101:=((HIGH+LOW+CLOSE)/3-MA((HIGH+LOW+CLOSE)/3,10))/(0.015*AVEDEV((HIGH+LOW+CLOSE)/3,10)); CCI51:=((HIGH+LOW+CLOSE)/3-MA((HIGH+LOW+CLOSE)/3,5))/(0.015*AVEDEV((HIGH+LOW+CLOSE)/3,5)); CCI31:=((HIGH+LOW+CLOSE)/3-MA((HIGH+LOW+CLOSE)/3,3))/(0.015*AVEDEV((HIGH+LOW+CLOSE)/3,3)); CCI买点定位1:=CROSS(CCI51,0) AND CROSS(CCI31,0) AND REF(CCI151,1)>0 AND REF(CCI101,1)>-30 AND REF(CCI151,1)>REF(CCI101,1) AND REF(CCI101,1)>REF(CCI51,1); CCI买点定位2:=CROSS(CCI31,0) AND CCI51>REF(CCI51,1) AND REF(CCI51,1)<-100 AND REF(CCI151,1)>0 AND REF(CCI101,1)>-30 AND REF(CCI151,1)>REF(CCI101,1) AND REF(CCI101,1)>REF(CCI51,1); CCI买点定位3:=CROSS(CCI51,0) AND CROSS(CCI31,0) AND REF(CCI101,1)>0 AND REF(CCI101,1)>REF(CCI151,1); CCI买点定位:=CCI买点定位1=1 OR CCI买点定位2=1 OR CCI买点定位3=1; 金牛1:=CCI买点定位=1 AND DEA12121>DEA18181 AND DEA18181>DEA24241 AND DEA24241>DEA36361 AND DEA36361>DEA511 AND DEA511>=DEA1021 AND DEA18181>REF(DEA18181,1) AND DEA24241>REF(DEA24241,1) AND DEA36361>REF(DEA36361,1) AND DEA511>REF(DEA511,1) AND DEA1021>REF(DEA1021,1) AND DEA36361>0 AND DEA331>0; 金牛2:=CCI买点定位=1 AND DEA12121>DEA18181 AND DEA18181>DEA24241 AND DEA24241>DEA36361 AND DEA18181>DEA1021 AND DEA18181>REF(DEA18181,1) AND DEA24241>REF(DEA24241,1) AND DEA36361>REF(DEA36361,1) AND DEA511>REF(DEA511,1) AND DEA1021>REF(DEA1021,1) AND DEA18181>0 AND DEA331>0; 金牛:=金牛1=1 OR 金牛2=1; VOL比:=VOL/REF(VOL,1); 高度:=(D90H1-D90L1)*4+D90H1; PBX11:=(EXPMA((CLOSE+HIGH+LOW)/3,4)+EMA((CLOSE+HIGH+LOW)/3,4*2)+EMA((CLOSE+HIGH+LOW)/3,4*4))/3; PBX22:=(EXPMA((CLOSE+HIGH+LOW)/3,5)+EMA((CLOSE+HIGH+LOW)/3,5*2)+EMA((CLOSE+HIGH+LOW)/3,5*4))/3; PBXHH:=(EXPMA(H,2)+EMA(H,2*2)+EMA(H,2*4))/3,COLORGREEN,LINETHICK1; PBXLL:=(EXPMA(L,2)+EMA(L,2*2)+EMA(L,2*4))/3,COLORRED,LINETHICK1; 牛魔王:=(CLOSE+HIGH+LOW)/3>Y1M AND 金牛=1 AND PBX11>PBX22 AND VOL比>1 AND C<高度; STICKLINE(牛魔王=1,LOW,HIGH,0,0),COLORYELLOW; STICKLINE(牛魔王=1,CLOSE,OPEN,4,0),COLORYELLOW; DRAWICON(牛魔王=1,L,5); YM高:=EMA(SLOPE(H,24)*20+H,48),COLORGREEN,DOTLINE; YM低:=EMA(SLOPE(L,24)*20+L,48),COLORGREEN,DOTLINE; 止损:=(HIGH+LOW)/2-(YM高-YM低)*1.5; 止盈1:=(HIGH+LOW)/2+(YM高-YM低)*2; 止盈2:=(HIGH+LOW)/2+(YM高-YM低)*4; 止盈3:=(HIGH+LOW)/2+(YM高-YM低)*6; 止盈4:=(HIGH+LOW)/2+(YM高-YM低)*8; 止盈5:=(HIGH+LOW)/2+(YM高-YM低)*10; STICKLINE(牛魔王=1,止损,止损,100,0),LINETHICK1,COLORWHITE; STICKLINE(牛魔王=1,止盈1,止盈1,20,0),LINETHICK1,COLORWHITE; STICKLINE(牛魔王=1,止盈2,止盈2,30,0),LINETHICK1,COLORWHITE; STICKLINE(牛魔王=1,止盈3,止盈3,40,0),LINETHICK1,COLORWHITE; STICKLINE(牛魔王=1,止盈4,止盈4,50,0),LINETHICK1,COLORWHITE; STICKLINE(牛魔王=1,止盈5,止盈5,60,0),LINETHICK1,COLORWHITE; DRAWTEXT(牛魔王=1,止损*0.98,'↖【止损】'),COLORWHITE; ZQ:=220; P1:=CONST(LLV(INDEXL,ZQ));PC:=CONST(HHV(INDEXH,ZQ))-P1; J1:=CONST(LLV(L,ZQ)); JC:=CONST(HHV(H,ZQ))-J1; JPB:=JC/PC; 大盘最低:=J1+(INDEXL-P1)*JPB; 大盘最高:=J1+(INDEXH-P1)*JPB; 大盘开盘:=J1+(INDEXO-P1)*JPB; 大盘收盘:=J1+(INDEXC-P1)*JPB; 大盘YM:=EMA(SLOPE((大盘收盘+大盘最高+大盘最低)/3,24)*20+(大盘收盘+大盘最高+大盘最低)/3,48),COLORRED,DOTLINE; 3、黄金手指,典藏 MA1:MA(CLOSE,5); MA2:MA(CLOSE,10); MA3:MA(CLOSE,25); MA4:MA(CLOSE,60); MA5:MA(CLOSE,610); DRAWTEXT_FIX(1,0.00,0,0,HYBLOCK)COLOR0080FF; DRAWTEXT_FIX(1,0.14,0,0,DYBLOCK)COLOR00FFFF; DRAWTEXT_FIX(1,0.00,0.06,0,EXTERNSTR(0,1))COLOR0000FF; DRAWTEXT_FIX(1,0.00,0.12,0,EXTERNSTR(0,2))COLORFF00FF; DRAWTEXT_FIX(1,0.00,0.18,0,EXTERNSTR(0,3))COLORFF88FF; DRAWTEXT_FIX(1,0.00,0.24,0,EXTERNSTR(0,5)),COLORLICYAN; 箱底:=TROUGH(CLOSE,10,1)*1.02,COLOR008888,LINETHICK2; 价低箱底:=COUNT(L<箱底,3); 底箱:=TROUGH(CLOSE,10,1)*1.05,COLOR008888,LINETHICK1; DRAWTEXT(价低箱底>=1 AND 箱底<MA3 AND CROSS(C,底箱),L*0.9999,'杀入'),COLOR00CCCC; DRAWTEXT(MA3>MA4 AND 价低箱底>=1 AND 箱底<MA3 AND CROSS(C,底箱),L*0.9999,'杀入加强'),COLOR00CCCC; 金手指:价低箱底>=1 AND 箱底<MA3 AND CROSS(C,底箱),COLOR00AAAA,NODRAW; STICKLINE(金手指,OPEN,CLOSE,2.0,0),COLOR008888; STICKLINE(金手指,OPEN,CLOSE,1.6,0),COLOR00AAAA; STICKLINE(金手指,OPEN,CLOSE,0.8,0),COLOR00CCCC; STICKLINE(金手指,OPEN,CLOSE,0.2,0),COLOR00FFFF; 止跌:=(REF(EVERY(C<O,2),1) AND C>O); VAR1N:=MA(CLOSE,5),; VAR2N:=MA(CLOSE,10); VAR3N:=(VAR1N-CLOSE)/CLOSE>3/100; VAR4N:=(VAR2N-VAR1N)/VAR1N>0.03; VAR5N:=LLV(CLOSE,30)=LLV(CLOSE,120); 底部:=VAR3N AND VAR4N AND VAR5N; STICKLINE(BARSLAST(底部)<=2 AND 止跌,OPEN,CLOSE,2.0,0),COLORFF0066; 短趋势线:=MA(CLOSE,13),COLORRED,LINETHICK3; 中线:=MA(CLOSE,33),LINETHICK1; 中趋势线:=MA(CLOSE,55),LINETHICK1,COLORGRAY; 上极限:=((C-REF(MA(CLOSE,20),1))/20+短趋势线)*1.20; DRAWTEXT(CROSS(短趋势线,C) AND INDEXC>MA(INDEXC,13) AND 短趋势线>REF(短趋势线 ,1) AND V<REF(V,1) AND 短趋势线>中趋势线 ,L*0.985,'买入'),COLORRED; 箱顶:=PEAK(CLOSE,10,1)*1.001,COLORFF4400; www70822Com:=PEAK(CLOSE,10,1)*1.001,COLORFF4400; RESV:=(CLOSE-LLV(LOW,13))/(HHV(HIGH,13)-LLV(LOW,13))*100; KEE:=SMA(RESV,3,1); DEE:=SMA(KEE,3,1); JEE:=3*KEE-2*DEE; RSV24:=(CLOSE-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))*100; K24:=SMA(RSV24,3,1); D24:=SMA(K24,3,1); J24:=3*K24-2*D24; 压力位:=IF(CROSS(J24,JEE),H,REF(H,BARSLAST(CROSS(J24,JEE)))),COLOR669900,LINETHICK1; 支撑位:=IF(CROSS(JEE,J24),L,REF(L,BARSLAST(CROSS(JEE,J24)))),COLORCE6700,LINETHICK2; 追涨:=压力位<箱顶 AND CROSS(C,箱顶); DRAWTEXT(压力位<箱顶 AND CROSS(C,箱顶),L,'追涨'),COLORCC8868; A1:=REF(V,1);A2:=DVOL;A3:=A2/A1; LNX:=A3-REF(A3,1),COLOR00CCCC,LINETHICK1; E1:=REF(C,1);E2:=DCLOSE;E3:=(E2-E1)/E1*100; QMX:=E3-REF(E3,1),COLOR00CCCC,LINETHICK2; XG:=CROSS(LNX,500) AND CROSS(QMX,10); DRAWTEXT(XG=1,L*0.985,'金手指'),COLORCC8868; DRAWICON(XG=1,L*0.99,11); |