绝世划线主图: A1:=REF(HIGH,3)=HHV(HIGH,2*3+1); B1:=FILTER(A1,3); C1:=BACKSET(B1,3+1); D1:=FILTER(C1,3);{高点} A2:=REF(LOW,3)=LLV(LOW,2*3+1); B2:=FILTER(A2,3); C2:=BACKSET(B2,3+1); D2:=FILTER(C2,3);{低点} E1:=(REF(LLV(LOW,2*3),1)+REF(HHV(HIGH,2*3),1))/2; E2:=(HIGH+LOW)/2;{高低点出现在同一K线上时可作取舍} H1:=(D1 AND NOT(D2 AND E1>=E2)) OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1; H2:=D1 AND NOT(D2 AND E1>=E2); L1:=D2 AND NOT(D1 AND E1=E2); X1:=REF(BARSLAST(H1),1)+1; F1:=BACKSET(H1 AND COUNT(L1,X1)>0,LLVBARS(IF(L1,LOW,10000),X1)); G1:=F1>REF(F1,1); I1:=BACKSET(G1,2); LD:=I1>REF(I1,1);{过滤后低点} L2:=LD OR BARSTATUS=2 OR BARSCOUNT(CLOSE)=1; X2:=REF(BARSLAST(L2),1)+1; F2:=BACKSET(L2 AND COUNT(H2,X2)>0,HHVBARS(IF(H2,HIGH,0),X2)); G2:=F2>REF(F2,1); I2:=BACKSET(G2,2); HD:=I2>REF(I2,1);{过滤后高点} DRAWLINE(LD,L,HD,H,0),COLORWHITE,LINETHICK1,POINTDOT; DRAWLINE(HD,H,LD,L,0),COLORWHITE,LINETHICK1,POINTDOT; J1:=BACKSET(BARSTATUS=2,MIN(BARSLAST(HD),BARSLAST(LD))+1); J2:=J1>REF(J1,1); DRAWLINE(J2,IF(HD,H,L),BARSTATUS=2,IF(BARSLAST(HD)>BARSLAST(LD),H,L),0),COLORWHITE,LINETHICK1,POINTDOT; A3:=H; B3:=REF(H,REF(BARSLAST(HD),1)+1)>REF(H,REF(BARSLAST(HD),1)+2+REF(BARSLAST(HD),REF(BARSLAST(HD),1)+2)); D3:=A3 AND B3 AND HD; E3:=BACKSET(D3,REF(BARSLAST(HD),1)+2); HH:=E3>REF(E3,1);{找出全部长期高点} A4:=L>REF(L,REF(BARSLAST(LD),1)+1); B4:=REF(L,REF(BARSLAST(LD),1)+1); D4:=A4 AND B4 AND LD; E4:=BACKSET(D4,REF(BARSLAST(LD),1)+2); LL:=E4>REF(E4,1);{找出全部长期低点} DRAWICON(HH,H,5),ALIGN1; DRAWICON(LL,L,4),ALIGN1; H3:=HH OR BARSTATUS=2 OR BARSCOUNT(C)=1; {后面进行过滤,方法同前。只是不用考虑高低点出现在同一K线} X3:=REF(BARSLAST(H3),1)+1; F3:=BACKSET(H3 AND COUNT(LL,X3)>0,LLVBARS(IF(LL,L,POW(10,20)),X3)); G3:=F3>REF(F3,1); I3:=BACKSET(G3,2); LZ:=I3>REF(I3,1); {长期低点,也可供引用} L4:=LZ OR BARSTATUS=2 OR BARSCOUNT(C)=1; X4:=REF(BARSLAST(L4),1)+1; F4:=BACKSET(L4 AND COUNT(HH,X4)>0,HHVBARS(IF(HH,H,-POW(10,20)),X4)); G4:=F4>REF(F4,1); I4:=BACKSET(G4,2); HZ:=I4>REF(I4,1);{长期高点,也可供引用} DRAWLINE(HZ,H,LZ,L,0),COLORGREEN,LINETHICK1; DRAWLINE(LZ,L,HZ,H,0),COLORGREEN,LINETHICK1;{长期连线} K1:=BACKSET(BARSTATUS=2,MIN(BARSLAST(HZ),BARSLAST(LZ))+1); K2:=K1>REF(K1,1); DRAWLINE(K2,IF(HZ,H,L),BARSTATUS=2,C,0),COLORGREEN,LINETHICK1; {最后的长期连线,连在收盘价上} UU:=BACKSET(BARSTATUS=2,BARSLAST(LD)+1); VV:=UU>REF(UU,1); WW:=BACKSET(VV,REF(BARSLAST(LD),1)+2); XX:=WW>REF(WW,1); DRAWLINE(XX,L,VV,L,1),COLORMAGENTA,LINETHICK1; UU2:=BACKSET(BARSTATUS=2,BARSLAST(HD)+1); VV2:=UU2>REF(UU2,1); WW2:=BACKSET(VV2,REF(BARSLAST(HD),1)+2); XX2:=WW2>REF(WW2,1); DRAWLINE(XX2,H,VV2,H,1),COLORMAGENTA,LINETHICK1; 前一低:REF(L,BARSLAST(VV)),COLOR99FF66,POINTDOT,LINETHICK3; 前二低:REF(L,BARSLAST(XX)),COLORFF66FF,POINTDOT,LINETHICK3; 前一高:REF(H,BARSLAST(VV2)),COLOR99FF66,POINTDOT,LINETHICK3; 前二高:REF(H,BARSLAST(XX2)),COLORFF66FF,POINTDOT,LINETHICK3; 短高:=REF(H,BARSLAST(VV2)); 短低:=REF(L,BARSLAST(VV)); 短比: (C-短低)/(短高-短低),LINETHICK0; {以下语句为三角形部分} {分析家公式网www.70822.com} 底:REF(L,BARSLAST(VV)),COLORred,LINETHICK2; 頂:REF(H,BARSLAST(VV2)),COLORGreen,LINETHICK2; {下迭三角形:藍色三角形畫完介入} StickLine(VV,頂,底,0,0),Colorff6633,linethick3;{} DRAWLINE(VV2,H,VV,L,0),Colorff6633,linethick3;{斜} DRAWLINE(VV2,H,VV,頂,0),Colorff6633,linethick3;{?} {DRAWLINE(c>0,H,VV,L,0),Colorcyan,linethick2;}{斜} {DRAWLINE(c>1,H,VV,頂,0),Colorcyan,linethick2;}{?} {上漲三角形:紅色三角形畫完出局} StickLine(VV2 ,頂,底,0,0),Colorred,linethick3;{} DRAWLINE(VV,L,VV2,H,0),Colorred,linethick3;{斜} DRAWLINE(VV,L,VV2,底,0),Colorred,linethick3;{?}; 快抢短线(顶尖财经 股票学院: www.58188.com): input:N(26,2,100); {DRAWGBK(CLOSE>0,STRIP(RGB(0,150,130),RGB(0,0,0),1));} RSVp:=(C-LLV(L,30))/(HHV(H,30)-LLV(L,30))*100-50; Kv:=SMA(RSVp,3,1); Dv:=SMA(Kv,3,1); Jv:=3*Kv-2*Dv; zdzk1:=EMA(Jv,6); zdzk2:=REF(zdzk1,1); 做多:IF(zdzk1>=zdzk2,zdzk1+2,zdzk2),PRECIS2,COLORRED; 做空:IF(zdzk2-zdzk1,zdzk2,zdzk1),PRECIS2,COLORGREEn; xw1:=IF(O<=REF(O,1),0,MAX((H-O),(O-REF(O,1)))); xw2:=IF(O>=REF(O,1),0,MAX((O-L),(O-REF(O,1)))); xw3:=SUM(xw1,21); xw4:=SUM(xw2,21); xw5:=IF(xw3>xw4,(xw3-xw4)/xw3,IF(xw3=xw4,0,(xw3-xw4)/xw4)); {14天强弱} RS:=SMA(MAX(C-REF(C,1),0),14,1)/SMA(ABS(C-REF(C,1)),14,1)*100; ZD:= EMA(EMA(EMA(RS,7),3),3); ZD1:=(ZD-REF(ZD,1))/REF(ZD,1)*15; STICKLINE(ZD1>=0,0,ZD1*50,4,0),Color0000BE; STICKLINE(ZD1<=0,0,ZD1*50,4,0),COLORCYAN; y1:=AMOUNT/V/100; y2:=(3*H+L+O+2*C)/7; y3:=100*(WINNER(1.1*C)-WINNER(0.9*C)); y4:=SUM(AMOUNT,13)/y1/100; y5:= DMA(y2,V/y4); y6:=(C-y5)/y5*100; y7:=(y3<10) AND (y6<=-10); y8:=SMA(MAX(C-REF(C,1.5),0),6,1)/SMA(ABS(C-REF(C,1.5)),6,1)*100; 重亏:STICKLINE(y6<=-10 and ZD1<0,ZD1*55,ZD1*45,6,0),ColorFF89B2; 全亏:STICKLINE(y6<=-16 and ZD1<0,ZD1*60,ZD1*55,6,1),COLORBLUE; 超跌:STICKLINE(y7 and ZD1<0,ZD1*65,ZD1*60,6,0),color399c7f; Jct:=100*(c-cost(10))/cost(10); PARTLINE(C,if(Jct<0,Jct,0)*3),color399c7f; {备战区1} ZDD1:=(HHV(H,21)-C)/(HHV(H,21)-LLV(L,21))*100-10; ZDD2:=(C-LLV(L,21))/(HHV(H,21)-LLV(L,21))*100; ZDD3:=SMA(ZDD2,13,8); ZDD4:=CEILING(SMA(ZDD3,13,8)); ZDD5:=SMA(ZDD1,21,8); Xh1:=SMA(MAX(C-REF(C,2),0),7,1)/SMA(ABS(C-REF(C,2)),7,1)*100; Xh2:=ZDD4-ZDD5<-65 and Xh1<12; 备战区:DRAWICON(Xh2,0,12),Color006EFF; STICKLINE(Xh2,0,ZD1*20,4,0),Color006EFF; {备战区2} Xx1:=MA(LOW,2)*0.96; Xx2:=MA(LOW,26)*0.85; Xx3:= REF(Xx1,1)<Xx2 AND REF(Xx1,1)<Xx1 AND REF(Xx1,1)<REF(Xx1,2);{30} STICKLINE(Xx3,0,ZD1*16,4,0),Color006EFF; DRAWICON(Xx3,0,12); {备战区3} C0:=REF(C,2)*0.865; C1:=REF(C,13)*0.772; DSY:=100*vol/CApitAl; STICKLINE((C-MIN(C0,C1))/C<0.1 AND SUM(DSY,5)/5<1.8,0,ZD1*25,4,0),Color006EFF; DRAWICON((C-MIN(C0,C1))/C<0.1 AND SUM(DSY,5)/5<1.8,0,12); {备战区4} Ww1:= sum( ma(c,10),9)/10.110; Ww2:=cross(c,Ww1); STICKLINE(Ww2,0,ZD1*26,4,0),Color006EFF;{40} DRAWICON(Ww2,0,12); {买1} Vw1:=DMA(EMA(C,12),SUM(V,5)/3/CAPITAL); Vw2:=REF(H,10)/C>1.35; Vw3:=(COST(20)-C)/C>0.15; Vw4:=H>L*1.051; Vw5:=Vw4 AND COUNT(Vw4,5)>1; Vw6:=(((C-Vw1)/Vw1*100<-30) or Vw2) and Vw3 and Vw5; STICKLINE(Vw6,0,ZD1*40,4,0),Color0000FF;{48} {买2} XL1:=MA(LOW,2)*0.96; XL2:=MA(LOW,26)*0.85; XL3:=REF(XL1,1)<XL2 AND REF(XL1,1)<XL1 AND REF(XL1,1)<REF(XL1,2); STICKLINE(XL3,0,15,4,0),Colorred; DRAWTEXT(XL3,15,'←买'),Colorred; {井喷} jjp1:=REF(INDEXC,1); jjp2:=FILTER((INDEXC-jjp1)/jjp1>0.03 and zdzk1>=zdzk2,7); STICKLINE(jjp2,0,-15,4,0),Colorred; DRAWTEXT(jjp2,-15,'←买'),Colorred; {//数据源} x1:=EMA(HHV(H,500),21); x2:=EMA(HHV(H,250),21); x3:=EMA(HHV(H,90),21); x4:=EMA(LLV(L,500),21); x5:=EMA(LLV(L,250),21); x6:=EMA(LLV(L,90),21); x7:=EMA((x1*0.558+x2*0.558+x3*0.558+x4*0.96+x5*0.96+x6*0.96)/6,21); x8:=EMA((x1*0.55 +x2*0.55+ x3*0.65+ x4*1.25+x5*1.23+x6*1.2 )/6,21); x9:=EMA((x1*0.68+ x2*0.68+ x3*0.68+ x4*1.3 +x5*1.3+ x6*1.3 )/6,21); VARA:=EMA((x7*3+x8*2+x9)/6*1.738,21); VARB:=REF(LOW,1); VARC:=SMA(ABS(LOW-VARB),3,1)/SMA(MAX(LOW-VARB,0),3,1)*100; VARD:=EMA(IF(C*1.35<=VARA,VARC*10,VARC/10),3); {//C*1.35小于等于数据源取低价强弱线*10的3日均线,否则取低价强弱线/10的3日均线} VARE:=LLV(L,30); VARF:=HHV(VARD,30); VAR10:=IF(MA(C,58),1,0); VAR11:=EMA(IF(LOW<=VARE,(VARD+VARF*2)/2,0),3)/618*VAR10; MID:=REF(H+L,1)/2; CR:=SUM(MAX(0,H-MID),N)/SUM(MAX(0,MID-L),N)*100; 出击:IF(CR<60 AND VAR11>10,35{6000/CR},0),COLORGREEN; 攻击:IF (VAR11>20,{VAR11*3}30,0),COLOR0033ff; {加仓} xc1:=(MA(C,80)-MA(C,13)/3); xc2:= MA((C-xc1)/xc1,1); xc3:=ema(xc2,12)*0.7; xc4:=ema(xc2,3); xc5:=if(llv(xc4-xc3,12)>0,0,-10); xc6:=EMA(C,12)-EMA(C,26); xc7:=EMA(xc6,9); xc8:=2*(xc6-xc7); 加仓:if(xc5<0 and cross(xc8,0),50,0),LINETHICK1,colorblue; DRAWTEXT(加仓,35,'←加仓'),colorblue; |