{N:1,111,5} ZGD:=HHV(H,50); ZGD2:=CONST(ZGD)*1.05; ZDD:=LLV(L,50); ZDD2:=CONST(ZDD)*0.95; DRAWBAND(ZGD2,RGB(100,100,100),ZDD2,RGB(00,00,00)); GJ:=(C+H+L+O)/4; 明日阻力:L+(GJ-L)+(C-L); 明日支撐:L+(C-GJ); 今日阻力:REF(明日阻力 , 1),NODRAW; 今日支撐:REF(明日支撐 , 1),NODRAW; 下檔線:=(((CLOSE - LLV(LOW,13)) / (HHV(HIGH,13) - LLV(LOW,13))) * 100); RRRSV:=SMA(下檔線,3,1); KKK:=SMA(RRRSV,3,1); DDDDD:=((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)); 壓力2:=IF(CROSS(D24,DDDDD),HIGH,REF(HIGH,BARSLAST(CROSS(D24,DDDDD)))),COLORFFFFFF; 壓力位:IF(ISLASTBAR,壓力2,DRAWNULL),NODRAW; 底部:=LLV(HIGH,30),COLOR00FF00; 底部位:IF(ISLASTBAR,底部,DRAWNULL),NODRAW; AA:=REF(H,N)=HHV(H,2*N+1); QY:=BACKSET(AA,N+1); CC:=FILTER(QY,N) AND H=HHV(H,N+1); DDD:BARSLAST(CC),NODRAW; GDTS:IF(CC,CURRBARSCOUNT,0),NODRAW; DINGBUTS:IF(DDD,REF(GDTS,DDD),GDTS),NODRAW; GDCS1:CONST(DINGBUTS),NODRAW; GDCS13:=CONST(REF(HIGH,GDCS1-1)); DINGBUTS1:REF(DINGBUTS,DDD+1),NODRAW; GDCS2:=CONST(DINGBUTS1); GDCS23:=CONST(REF(HIGH,DINGBUTS1-1)); XG1:=BACKSET(ISLASTBAR,GDCS1); XG2:=BACKSET(ISLASTBAR,DINGBUTS1); 高點壓力:=DRAWLINE(CURRBARSCOUNT=GDCS2,H,CURRBARSCOUNT=GDCS1,H,1) ,COLORBLUE,LINETHICK1; AA1:=REF(L,N)=LLV(L,2*N+1); QY1:=BACKSET(AA1,N+1); CC1:=FILTER(QY1,N) AND L=LLV(L,N+1); DD1:=BARSLAST(CC1); DDTS:=IF(CC1,CURRBARSCOUNT,0); DDTS1:=IF(DD1,REF(DDTS,DD1),DDTS); DDCS1:=CONST(DDTS1); DDCS13:=CONST(REF(L,DDCS1-1)); DDTS2:=REF(DDTS1,DD1+1); DDCS2:=CONST(DDTS2); DDCS23:=CONST(REF(L,DDTS2-1)); XD1:=BACKSET(ISLASTBAR,DDCS1); XD2:=BACKSET(ISLASTBAR,DDTS2); 低點支撐:=DRAWLINE(CURRBARSCOUNT=DDCS2,L,CURRBARSCOUNT=DDCS1,L,1),COLORBLUE,LINETHICK1; DRAWBAND(高點壓力,RGB(00,00,100),低點支撐,RGB(00,00,00)); ZGSTAR:=(高點壓力+低點支撐)/2; ZGEND:=CONST((高點壓力+低點支撐)/2); STARDAY:=IF(DDCS2<GDCS2,DDCS2,GDCS2); 中軌:DRAWLINE(CURRBARSCOUNT=STARDAY,ZGSTAR,ISLASTBAR,ZGEND,1),COLOR555555,LINETHICK1; M:=INTPART(3*N/5); AAA:=REF(H,M)=HHV(H,2*M+1); QYY:=BACKSET(AAA,M+1); CCC:=FILTER(QYY,M) AND H=HHV(H,M+1); DDDD:=BARSLAST(CCC),NODRAW; GDTSS:=IF(CCC,CURRBARSCOUNT,0),NODRAW; DINGBUTSS:=IF(DDDD,REF(GDTSS,DDDD),GDTSS),NODRAW; GDCS11:=CONST(DINGBUTSS),NODRAW; DINGBUTS11:REF(DINGBUTSS,DDDD+1),NODRAW; GDCS22:=CONST(DINGBUTS11); 高點壓力M:DRAWLINE(CURRBARSCOUNT=GDCS22,H,CURRBARSCOUNT=GDCS11,H,1),COLORRED,LINETHICK1; AA11:=REF(L,M)=LLV(L,2*M+1); QY11:=BACKSET(AA11,M+1); CC11:=FILTER(QY11,M) AND L=LLV(L,M+1); DD11:=BARSLAST(CC11); DDTSS:=IF(CC11,CURRBARSCOUNT,0); DDTS11:=IF(DD11,REF(DDTSS,DD11),DDTSS); DDCS11:=CONST(DDTS11); DDTS22:=REF(DDTS11,DD11+1); DDCS22:=CONST(DDTS22); 低點支撐M:DRAWLINE(CURRBARSCOUNT=DDCS22,L,CURRBARSCOUNT=DDCS11,L,1) COLORRED,LINETHICK1; STICKLINE(XG2,GDCS23,GDCS23,0.5,1),COLORWHITE,LINETHICK3; STICKLINE(XG1,GDCS13,GDCS13,0.5,1),COLORYELLOW,LINETHICK3; STICKLINE(XD2,DDCS23,DDCS23,0.5,1),COLORMAGENTA,LINETHICK3; STICKLINE(XD1,DDCS13,DDCS13,0.5,1),COLORCYAN,LINETHICK3; STICKLINE(ISLASTBAR AND C>=今日阻力,今日阻力,今日阻力,10,1),LINETHICK2,COLOR0000FF; STICKLINE(ISLASTBAR AND C<今日阻力,今日阻力,今日阻力,10,1),LINETHICK2,COLOR00FF00; STICKLINE(ISLASTBAR AND C>=今日支撐,今日支撐,今日支撐,10,1),LINETHICK2,COLORFF00FF; STICKLINE(ISLASTBAR AND C<今日支撐,今日支撐,今日支撐,10,1),LINETHICK2,COLORFF8800; STICKLINE(ISLASTBAR ,壓力位,壓力位,120,0),LINETHICK4,COLORFFFFFF; STICKLINE(ISLASTBAR ,底部位,底部位,100,0),LINETHICK4,COLOR00FF00; MA1:MA(CLOSE,5); MA2:MA(CLOSE,10); MA3:MA(CLOSE,20); MA4:MA(CLOSE,60); DRAWKLINE(H,O,L,C); ********************************************************************************** {VOL} 日換:V/CAPITAL*100,LINETHICK0; HS:=V/CAPITAL*100; 三換:SUM(HS,3),COLORFFFFFF,LINETHICK2; 五換:SUM(HS,5),COLORFFFFFF,LINETHICK2; 百日總:=SUM(V,100); 百日換:百日總/CAPITAL*100,LINETHICK0; 量:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN)); 買量:=IF(CLOSE>OPEN,量*(HIGH-LOW),IF(CLOSE<OPEN,量*((HIGH-OPEN)+(CLOSE-LOW)),VOL/2)),LINETHICK0; 賣量:=(IF(CLOSE>OPEN,0-量*((HIGH-CLOSE)+(OPEN-LOW)),IF(CLOSE<OPEN,0-量*(HIGH-LOW),0-VOL/2)))*-1,LINETHICK0; 總量:=買量+賣量,LINETHICK0; 凈量:=買量-賣量,LINETHICK0; 主動買萬:買量/10000,COLORRED,NODRAW; 主動賣萬:賣量/10000,COLORGREEN,NODRAW; 總手:主動買萬+主動賣萬,LINETHICK0; 總凈:主動買萬-主動賣萬,LINETHICK0; MAA:=MA( CLOSE ,2) ; STICKLINE(C>MAA,總量,1,4,1 ),COLOR00FFFF; STICKLINE(C<MAA,總量,1,4,1 ),COLORFF00FF; STICKLINE(凈量<0,1,總量,4,1),COLORFFFF00; STICKLINE(C<MAA AND 凈量>0,凈量,1,4,1 ),COLOR0000FF; STICKLINE(V>=2*REF(V,1),1,總量,4,1),COLOR0000FF; STICKLINE(總量>1,總量,0,2.8,0),COLOR353500; STICKLINE(總量>1,總量,0,2,0),COLOR555500; STICKLINE(總量>1,總量,0,1,0),COLOR757500; STICKLINE(總量>1,總量,0,0.1,0),COLOR959500; STICKLINE(買量>0,0,買量,2.8,0),COLOR000099; STICKLINE(買量>0,0,買量,2,0),COLOR0000AA; STICKLINE(買量>0,0,買量,1,0),COLOR0000FF; STICKLINE(買量>0,0,買量,0.1,0),COLORCC00FF; STICKLINE(凈量>0,0,凈量,2.8,0),COLOR0033FF; STICKLINE(凈量>0,0,凈量,2,0),COLOR0077FF; STICKLINE(凈量>0,0,凈量,1,0),COLOR00BBFF; STICKLINE(凈量>0,0,凈量,0.1,0),COLOR00FFFF; STICKLINE(凈量<0,1,凈量,3.8,1),COLORFFFF00; STICKLINE(凈量<0,0,凈量,3,0),COLOR005500; STICKLINE(凈量<0,0,凈量,2,0),COLOR009900; STICKLINE(凈量<0,0,凈量,1,0),COLOR00BB00; STICKLINE(凈量<0,0,凈量,0.1,0),COLOR00FF00; STICKLINE(C<MAA AND 凈量>0,凈量,0,2.8,0 ),COLOR777777; STICKLINE(C<MAA AND 凈量>0,凈量,0,2,0 ),COLOR999999; STICKLINE(C<MAA AND 凈量>0,凈量,0,1,0 ),COLORBBBBBB; STICKLINE(C<MAA AND 凈量>0,凈量,0,0.1,0 ),COLORFFFFFF; MA5:MA(VOL,5); MA10:MA(VOL,10); MA20:MA(VOL,20),COLOR00FFFF; DRAWICON(CROSS(MA5,MA10),(MA5 - 0.01),11); DRAWICON(CROSS(MA10,MA5),MA10,12); N:=35;N1:=35; 今V:=總量/10000; 昨V:=REF(V,1)/10000; 中點:=REFDATE(HHV(V,N)/2,DATE); DRAWTEXT(CURRBARSCOUNT=N,中點*1.3,'昨比量能:'),COLORDD00FF; STICKLINE(CURRBARSCOUNT=N1,中點*1.88,中點*1.52,昨V,0),COLORFF3300; STICKLINE(CURRBARSCOUNT=N1,中點*1.82,中點*1.58,昨V,0),COLORFF7700; STICKLINE(CURRBARSCOUNT=N1,中點*1.76,中點*1.64,昨V,0),COLORFF9900; STICKLINE(CURRBARSCOUNT=N1,中點*1.7,中點*1.7,昨V,0),COLORFFDD00; STICKLINE(CURRBARSCOUNT=N1,中點*1.76,中點*1.64,今V,0),COLOR0099FF; STICKLINE(CURRBARSCOUNT=N1,中點*1.7,中點*1.7,今V,0),COLOR00DDFF;
|