{一目均衡主圖} DRAWGBK(CLOSE,COLORRGB(10,160,0),COLORRGB(25,15,0),1); input:N1(8,1,100),N2(22,1,100),N3(44,1,100),M1(8,1,250); AX1:=MA(CLOSE,M1); AX2:=MA(CLOSE,M2); AX3:=MA(CLOSE,M3); CX1:=CROSS(AX1,AX2); CX2:=CROSS(AX2,AX1); CX3:=CROSS(AX3,AX2); CX4:=CROSS(AX2,AX3); 金蜘蛛:=CX1 AND CX4; 死蜘蛛:=CX2 AND CX3; DRAWTEXT(金蜘蛛,LOW*0.99,'金\n蜘\n蛛'),colorFF; DRAWTEXT(死蜘蛛,LOW*0.99,'死\n蜘\n蛛'),colorFF0000; 價托:=AX1>AX3 AND AX1>AX2 AND CROSS(AX2,AX3); DRAWTEXT(價托,LOW,'價\n托'),colorFF; 價壓:=AX1<AX3 AND AX1<AX2 AND CROSS(AX3,AX2); DRAWTEXT(價壓,LOW,'價\n壓'),colorFFFF; VAR1:=(2*CLOSE+OPEN+HIGH+LOW)/5; 轉(zhuǎn)換線:(HHV(HIGH,N1)+LLV(LOW,N1))/2,SHIFT3,LINETHICK1,colorFF; 基準(zhǔn)線:(HHV(HIGH,N2)+LLV(LOW,N2))/2,SHIFT3,LINETHICK1,colorFF6DD8; 先行帶B:REF((HHV(HIGH,N3)+LLV(LOW,N3))/2,N2),SHIFT3,LINETHICK1,color909090; 先行帶A:REF((轉(zhuǎn)換線+基準(zhǔn)線)/2,N2),SHIFT3,LINETHICK1,colorFFFF; 遲行帶:REF(CLOSE,N2),LINETHICK1,colorFF9224; AA:=(HHV(HIGH,120)-LLV(LOW,120))/30; 云帶A:REF((轉(zhuǎn)換線+基準(zhǔn)線)/2,N2),SHIFT3,LINETHICK1,colorFFFF; 云帶B:REF((HHV(HIGH,N3)+LLV(LOW,N3))/2,N2),SHIFT3,LINETHICK1,colorCCCCCC; STICKLINE(云帶A<云帶B,云帶A,云帶B,0.1,0.05),SHIFT3,color339933; STICKLINE(云帶A>=云帶B,云帶A,云帶B,0.1,0.01),SHIFT3,color33CC; DRAWTEXT(CROSS(轉(zhuǎn)換線,基準(zhǔn)線) AND VAR1<MIN(云帶A,云帶B),MIN(基準(zhǔn)線,LOW)*0.995,'▲'),ALIGN0,colorFF; DRAWTEXT(CROSS(基準(zhǔn)線,轉(zhuǎn)換線) AND VAR1>MAX(云帶A,云帶B),MAX(基準(zhǔn)線,HIGH)+AA,'▼'),ALIGN0,colorFF9966; DRAWTEXT(CROSS(轉(zhuǎn)換線,基準(zhǔn)線) AND VAR1<MIN(先行帶A,先行帶B),MIN(基準(zhǔn)線,LOW)*0.995,'▲'),ALIGN0,colorFF; DRAWTEXT(CROSS(轉(zhuǎn)換線,基準(zhǔn)線) AND RANGE(VAR1,MIN(先行帶A,先行帶B),MAX(先行帶A,先行帶B)),LOW*0.995,'▲\n▲'),ALIGN0,colorFF; DRAWTEXT(CROSS(轉(zhuǎn)換線,基準(zhǔn)線) AND VAR1>MAX(先行帶A,先行帶B),LOW-AA*0.5,'▲\n▲\n▲'),ALIGN0,colorFF; DRAWTEXT(CROSS(基準(zhǔn)線,轉(zhuǎn)換線) AND VAR1<MIN(先行帶A,先行帶B),MAX(基準(zhǔn)線,HIGH)+AA*2,'▼\n▼\n▼'),ALIGN0,colorFF9966; DRAWTEXT(CROSS(基準(zhǔn)線,轉(zhuǎn)換線) AND RANGE(VAR1,MIN(先行帶A,先行帶B),MAX(先行帶A,先行帶B)),MAX(基準(zhǔn)線,HIGH)+AA,'▼\n▼'),ALIGN0,colorFF9966; DRAWTEXT(CROSS(基準(zhǔn)線,轉(zhuǎn)換線) AND VAR1>MAX(先行帶A,先行帶B),MAX(基準(zhǔn)線,HIGH)+AA,'▼'),ALIGN0,colorFF9966; POLYLINE(NOT(BACKSET(ISLASTBAR,21)),REFX(CLOSE,21)),color66FFFF; POLYLINE(1,先行帶A),SHIFT21,color808080; POLYLINE(1,先行帶B),SHIFT21,color808080; STICKLINE(1,先行帶A,先行帶B,0.1,0),LINEDOT,SHIFT21,color808080; LSA:=REF(先行帶A,21); LSB:=REF(先行帶B,21); MID:MA(CLOSE,P),LINETHICK1; 強(qiáng)弱短:REF(EMA(CLOSE,5),1)*2-REF(EMA(CLOSE,11),1),colorFF00; 強(qiáng)弱長:REF(EMA(CLOSE,12),1)*2-REF(EMA(CLOSE,25),1),colorFFFFFF; 生命線:EMA(CLOSE,12),colorFF; UPPER:MID+2*STD(CLOSE,P),LINETHICK1; LOWER:MID-2*STD(CLOSE,P),LINETHICK1; 收盤線:=CLOSE; MM2:DRAWSL(ISLASTBAR,CLOSE,0,21,1),POINTDOT,colorFFFF; 早晨之星:=REF(CLOSE,2)/REF(OPEN,2)<0.95 AND REF(OPEN,1)<REF(CLOSE,2) AND (ABS(REF(OPEN,1)-REF(CLOSE,1)))/REF(CLOSE,1)<0.03 AND CLOSE/OPEN>1.05 AND CLOSE>REF(CLOSE,2); DRAWTEXT(早晨之星,LOW*0.97,'★\n早\n晨\n之\n星'),ALIGN2,PXUP6,colorFF00FF; 紅旗飄:=(HIGH-LOW)/LOW<0.092 AND (REF(HIGH,1)-REF(LOW,1))/REF(LOW,1)<0.092 AND (REF(HIGH,2)-REF(LOW,2))/REF(LOW,2)<0.092 AND CLOSE>OPEN AND REF(CLOSE,1)>REF(OPEN,1) AND REF(CLOSE,2)>REF(OPEN,2) AND (CLOSE-REF(CLOSE,3))/CLOSE<=0.12 AND ABS((REF(CLOSE,2)-REF(OPEN,2))/REF(CLOSE,2))<=0.043 AND ABS((REF(CLOSE,1)-REF(OPEN,1))/REF(CLOSE,1))<=0.043 AND (ABS(CLOSE-OPEN))/CLOSE<=0.043 AND REF(CLOSE,3)>=REF(CLOSE,4)*1.096 AND REF(CLOSE,3)<=REF(CLOSE,2) AND REF(OPEN,2)>=REF(CLOSE,3) AND REF(CLOSE,2)<=REF(CLOSE,1) AND REF(CLOSE,1)<=CLOSE; DRAWTEXT(紅旗飄,LOW*0.97,'★\n紅\n旗\n飄'),ALIGN2,PXUP6,colorFF; 金手指:=REF((HHV(HIGH,3)-LLV(LOW,3))/LLV(LOW,3),1)<=4.4/100 AND CLOSE>=REF(CLOSE,1)*1.095 AND ABS((OPEN-REF(CLOSE,1))/OPEN)<=0.033; DRAWTEXT(金手指,LOW*0.95,'★\n金\n手\n指'),ALIGN2,PXUP6,colorFFFF; VV1:=(HIGH-LOW)/LOW<0.05; 孕育線:=(REF(CLOSE,1)>=OPEN OR REF(OPEN,1)>=OPEN) AND CLOSE>REF(CLOSE,1)*1.095 AND (REF(HIGH,1)-REF(LOW,1))/REF(LOW,1)<=0.03; DRAWTEXT(孕育線,LOW*0.95,'★\n孕\(zhòng)n育\n線'),ALIGN0,PXUP6,colorFFFFFF; STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,0,0),colorFF00; STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,8,0),color8800; STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,7,0),color9900; STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,6,0),colorAA00; STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,5,0),colorBB00; STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,4,0),colorCC00; STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,3,0),colorDD00; STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,2,0),colorEE00; STICKLINE(OPEN>=CLOSE,CLOSE,OPEN,1,0),colorFF00; STICKLINE(OPEN>=CLOSE,OPEN,HIGH,1,0),color8800; STICKLINE(OPEN>=CLOSE,OPEN,HIGH,0.8,0),colorAA00; STICKLINE(OPEN>=CLOSE,OPEN,HIGH,0.5,0),colorCC00; STICKLINE(OPEN>=CLOSE,OPEN,HIGH,0.2,0),colorFF00; STICKLINE(OPEN>=CLOSE,CLOSE,LOW,1,0),color8800; STICKLINE(OPEN>=CLOSE,CLOSE,LOW,0.8,0),colorAA00; STICKLINE(OPEN>=CLOSE,CLOSE,LOW,0.5,0),colorBB00; STICKLINE(OPEN>=CLOSE,CLOSE,LOW,0.2,0),colorEE00; STICKLINE(CLOSE>OPEN,CLOSE,OPEN,0,0),colorFFBBFF; STICKLINE(CLOSE>OPEN,CLOSE,OPEN,8,0),colorFF00FF; STICKLINE(CLOSE>OPEN,CLOSE,OPEN,7,0),colorFF22FF; STICKLINE(CLOSE>OPEN,CLOSE,OPEN,6,0),colorFF44FF; STICKLINE(CLOSE>OPEN,CLOSE,OPEN,5,0),colorFF66FF; STICKLINE(CLOSE>OPEN,CLOSE,OPEN,4,0),colorFF88FF; STICKLINE(CLOSE>OPEN,CLOSE,OPEN,3,0),colorFF99FF; STICKLINE(CLOSE>OPEN,CLOSE,OPEN,2,0),colorFFAAFF; STICKLINE(CLOSE>OPEN,CLOSE,OPEN,1,0),colorFFBBFF; STICKLINE(CLOSE>OPEN,HIGH,CLOSE,1,0),colorFF00FF; STICKLINE(CLOSE>OPEN,HIGH,CLOSE,0.8,0),colorFF44FF; STICKLINE(CLOSE>OPEN,HIGH,CLOSE,0.5,0),colorFF88FF; STICKLINE(CLOSE>OPEN,HIGH,CLOSE,0.2,0),colorFFBBFF; STICKLINE(CLOSE>OPEN,OPEN,LOW,1,0),colorFF00FF; STICKLINE(CLOSE>OPEN,OPEN,LOW,0.8,0),colorFF44FF; STICKLINE(CLOSE>OPEN,OPEN,LOW,0.5,0),colorFF88FF; STICKLINE(CLOSE>OPEN,OPEN,LOW,0.2,0),colorFFBBFF; TY:=CLOSE; 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); A:=REF(CLOSE,BARSLAST(HD)); B:=REF(CLOSE,BARSLAST(LD)); T1:=BARSLAST(HD)<BARSLAST(LD) AND NOT(HD); T2:=BARSLAST(HD)>BARSLAST(LD) AND NOT(LD); 波浪頂:IF(T1,A,A),POINTDOT,LINETHICK3,colorFF00FF; STICKLINE(T1,A,A,9,0),colorFF00FF; 波浪底:IF(T2,B,B),POINTDOT,LINETHICK3,color80FF00; STICKLINE(T2,B,B,9,0),color80FF00; 波浪頂1:IF(T1,A,A),POINTDOT,SHIFT15,LINETHICK3,colorFF00FF; 波浪底1:IF(T2,B,B),POINTDOT,SHIFT15,LINETHICK3,color80FF00; DRAWNUMBER(CLOSE<OPEN AND CLOSE=波浪底,CLOSE*0.996,波浪底,2),colorFFFF; DRAWNUMBER(CLOSE>0 AND LOW=波浪底,LOW*0.998,波浪底,2),colorFFFF; DRAWNUMBER(CLOSE>OPEN AND CLOSE=波浪頂,CLOSE*1.008,波浪頂,2),colorFFFF; DRAWNUMBER(CLOSE<0 AND HIGH=波浪頂,HIGH*1.004,波浪頂,2),colorFFFF; |
|