MA5:MA(CLOSE,5);{背景}DRAWGBK(O>C,RGB(110,35,120),RGB(0,25,50),0,'0',0);DRAWKLINE(HIGH,OPEN,LOW,CLOSE);DRAWKLINE(H,O,L,C);今日競價額:DYNAINFO(15)/10000,NODRAW;DRAWTEXT_FIX(1,0.009,0.10,0,STRCAT('今日競價額:',STRCAT(VAR2STR(今日競價額,1),'萬')))COLORMAGENTA;今日競價量:DYNAINFO(15)/DYNAINFO(4)/100,NODRAW;DRAWTEXT_FIX(1,0.009,0.15,0,STRCAT('今日競價量:',STRCAT(VAR2STR(今日競價量,0),'手')))COLORMAGENTA;競價換手率:DYNAINFO(15)/OPEN/FINANCE(46)*100,NODRAW;DRAWTEXT_FIX(1,0.009,0.20,0,STRCAT('競價換手率:',STRCAT(VAR2STR(競價換手率,2),'%')))COLORMAGENTA;{主題概念}Z1:=STRCAT(HYBLOCK,'');Z2:=STRCAT(Z1,DYBLOCK);Z3:=STRCAT(Z2,'');DRAWTEXT_FIX(ISLASTBAR,0.05,0,0,STRCAT(Z3,GNBLOCK)),COLORCYAN;{帶狀線}DRAWBAND(MA(CLOSE,3),RGB(155,50,50),MA(CLOSE,5),RGB(0,91,0));DRAWBAND(MA(CLOSE,13),RGB(100,50,100),MA(CLOSE,15),RGB(0,0,180));DRAWKLINE(H,O,L,C);紅:MA(CLOSE,3),COLORBBBBBB{MA3};綠:MA(CLOSE,5),COLORYELLOW{MA5};AA:=紅>綠;紫:MA(CLOSE,13),COLORFF00CC{MA13};藍:MA(CLOSE,15),COLORABFF46{MA15};BB:=紫>藍;軍號:=MA(CLOSE,20)COLOR3399CC,NODRAW;臺階線:MA(CLOSE,30),NODRAW;臺階線1:STICKLINE(C>臺階線,臺階線,臺階線-0.01,3,0)COLOR3399CC;臺階線2:STICKLINE(C<臺階線,臺階線,臺階線-0.01,3,0)COLOR3399CC;N1:=6;mtm:=C-REF(C,1);ZLGJ:=100*EMA(EMA(MTM,N1),N1)/EMA(EMA(Abs(MTM),N1),N1);買1:=IF(LLV(ZLGJ,2)=LLV(ZLGJ,7)ANDCOUNT(ZLGJ<0,2)ANDcrOSS(ZLGJ,MA(ZLGJ,2)),1,0);賣1:=IF(HHV(ZLGJ,2)=HHV(ZLGJ,7)ANDCOUNT(ZLGJ>50,2)ANDCROSS(MA(ZLGJ,2),ZLGJ),1,0);STICKLINE(FILTER(買1=1,5),C,O,1,0),COLORRED;DRAWICON(FILTER(賣1=1,1),H*1.06,15),COLOR00FF00;STICKLINE(FILTER(賣1=1,1),C,O,1,0),COLOR00FF00;RSV:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;K:=SMA(RSV,3,1);D:=SMA(K,3,1);J:=3*K-2*D;BDGD:=HHV(J,2)=HHV(J,8)ANDJ>80;注意:=IF(CROSS(REF(J-0.01,1),J)ANDREF(BDGD,1),1,0);DRAWTEXT(注意AND賣1<1,HIGH*1.01,'J'),COLOR00FF00,LINETHICK3;STICKLINE(注意AND賣1<1,O,CLOSE,1,0),COLORYELLOW,LINETHICK2;{13天內}板後13天內:=COUNT(C/REF(C,1)>1.099,13)>1;XG:=FILTER(買1=1,5);錢袋:=板後13天內ANDXG;{註冊制漲停變色}BK:=IF(INBLOCK('科創板'),0.2,IF(INBLOCK('創業板'),0.2,IF(INBLOCK('ST板塊'),0.05,0.1)));XA_1:=IF(DATE<=1200823,1,0);STICKLINE((C>=ZTPRICE(REF(CLOSE,1),0.1)ANDC=H)ANDXA_1=1,O,C,2.7,0),COLORFF00FF;STICKLINE((C<=DTPRICE(REF(CLOSE,1),0.1)ANDC=L)ANDXA_1=1,O,C,2.7,0),COLORBLUE;STICKLINE((C>=ZTPRICE(REF(C,1),BK)ANDC=H),O,C,1,0),COLORYELLOW;STICKLINE((C<=DTPRICE(REF(C,1),BK)ANDC=L),O,C,1,0),COLORBLUE;STICKLINE((H>=ZTPRICE(REF(C,1),BK)ANDC<H)OR(H>=ZTPRICE(REF(CLOSE,1),0.1)ANDC<HANDXA_1=1),H,MAX(C,O),0.5,0),COLORMAGENTA;{漲停後回落}STICKLINE((L<=DTPRICE(REF(C,1),BK)ANDC>L)OR(L<=DTPRICE(REF(CLOSE,1),0.1)ANDC>LANDXA_1=1),L,MIN(C,O),0.5,0),COLORBLUE;{板塊定義}科創業板:=IF(INBLOCK('創業板')ORINBLOCK('科創板'),1,0);深圳股:=IF(INBLOCK('深證A股')AND科創業板=0,1,0);{漲停定義}漲停價:=IF(科創業板=1,ZTPRICE(REF(CLOSE,1),0.2),ZTPRICE(REF(CLOSE,1),0.1));{實施時間2022年7月11日,也就是說只新規股在11日出現:山西路橋}時間:=IF(DATE>1220769,1,1);{異動定義深證}老異動A:=(IF(REF(C,2)=REF(漲停價,2),1.10,REF(C,2)/REF(C,3))+IF(REF(C,1)=REF(漲停價,1),1.10,REF(C,1)/REF(C,2))+IF(C=漲停價,1.10,C/REF(C,1))-3)*100-(REF("399107$C",2)/REF("399107$C",3)+REF("399107$C",1)/REF("399107$C",2)+"399107$C"/REF("399107$C",1)-3)*100;{3天異動}老異動:=IF(老異動A>19.99,1,0);老異動價:=(REF("399107$C",2)/REF("399107$C",3)+REF("399107$C",1)/REF("399107$C",2)+"399107$C"/REF("399107$C",1)+0.2-IF(REF(C,2)=REF(漲停價,2),1.10,REF(C,2)/REF(C,3))-IF(REF(C,1)=REF(漲停價,1),1.10,REF(C,1)/REF(C,2)))*REF(C,1);新異動A:=(C/REF(C,2)-1)*100-("399107$C"/REF("399107$C",2)-1)*100;新異動B:=(C/REF(C,3)-1)*100-("399107$C"/REF("399107$C",3)-1)*100;新異動:=IF(新異動A>19.99,1,IF(新異動B>19.99,1,0));新異動價A:=(("399107$C"/REF("399107$C",2))+0.2)*REF(C,2);{2天就異動}新異動價B:=(("399107$C"/REF("399107$C",3))+0.2)*REF(C,3);{3天才異動}異動:=IF(時間=0AND老異動=1,1,IF(時間=1AND新異動=1,1,0));次異動:=IF(異動=1ANDEXISTR(異動=1,10,1)=0,1,0);第二次異動:=FILTER(IF(時間=0AND老異動=1ANDEXISTR(次異動=1,10,3)=1,1,IF(時間=1AND新異動A>19.99ANDEXISTR(次異動=1,10,2),1,IF(時間=1AND新異動B>19.99ANDEXISTR(次異動=1,10,3),1,0))),10);第三次異動:=FILTER(IF(時間=0AND老異動=1ANDEXISTR(第二次異動=1,10,3)=1,1,IF(時間=1AND新異動A>19.99ANDEXISTR(第二次異動=1,10,2),1,IF(時間=1AND新異動B>19.99ANDEXISTR(第二次異動=1,10,3),1,0))),10);第四次異動:=FILTER(IF(時間=0AND老異動=1ANDEXISTR(第三次異動=1,10,3)=1,1,IF(時間=1AND新異動A>19.99ANDEXISTR(第三次異動=1,10,2),1,IF(時間=1AND新異動B>19.99ANDEXISTR(第三次異動=1,10,3),1,0))),10);第五次異動:=FILTER(IF(時間=0AND老異動=1ANDEXISTR(第四次異動=1,10,3)=1,1,IF(時間=1AND新異動A>19.99ANDEXISTR(第四次異動=1,10,2),1,IF(時間=1AND新異動B>19.99ANDEXISTR(第四次異動=1,10,3),1,0))),10);第六次異動:=FILTER(IF(時間=0AND老異動=1ANDEXISTR(第五次異動=1,10,3)=1,1,IF(時間=1AND新異動A>19.99ANDEXISTR(第五次異動=1,10,2),1,IF(時間=1AND新異動B>19.99ANDEXISTR(第五次異動=1,10,3),1,0))),10);{馬丁丁指標}{異動線深證}MA1:MA(CLOSE,20);{DRAWNUMBER(PERIOD=5,L-0.2,第二次異動),COLORGREEN;}DRAWTEXT(PERIOD=5AND深圳股=1AND次異動=1,L,'次異動'),COLORYELLOW;DRAWSL(PERIOD=5AND時間=0AND深圳股=1AND次異動=1,老異動價,0,1,2),COLORGREEN,LINETHICK2;DRAWSL(PERIOD=5AND時間=1AND深圳股=1AND次異動=1AND新異動A>19.99,新異動價A,0,1,2),COLORGREEN,LINETHICK2;DRAWTEXT(PERIOD=5AND深圳股=1AND第二次異動=1,L,'第二次異動'),COLORYELLOW;DRAWSL(PERIOD=5AND時間=0AND深圳股=1AND第二次異動=1,老異動價,0,1,2),COLORGREEN,LINETHICK2;DRAWSL(PERIOD=5AND時間=1AND深圳股=1AND第二次異動=1AND新異動A>19.99,新異動價A,0,1,2),COLORGREEN,LINETHICK2;DRAWTEXT(PERIOD=5AND深圳股=1AND第三次異動=1,L,'第三次異動'),COLORYELLOW;DRAWSL(PERIOD=5AND時間=0AND深圳股=1AND第三次異動=1,老異動價,0,1,2),COLORGREEN,LINETHICK2;DRAWSL(PERIOD=5AND時間=1AND深圳股=1AND第三次異動=1AND新異動A>19.99,新異動價A,0,1,2),COLORGREEN,LINETHICK2;DRAWTEXT(PERIOD=5AND深圳股=1AND第四次異動=1,L,'第四次異動'),COLORYELLOW;DRAWSL(PERIOD=5AND時間=0AND深圳股=1AND第四次異動=1,老異動價,0,1,2),COLORGREEN,LINETHICK2;DRAWSL(PERIOD=5AND時間=1AND深圳股=1AND第四次異動=1AND新異動A>19.99,新異動價A,0,1,2),COLORGREEN,LINETHICK2;DRAWTEXT(PERIOD=5AND深圳股=1AND第五次異動=1,L,'第五次異動'),COLORYELLOW;DRAWSL(PERIOD=5AND時間=0AND深圳股=1AND第五次異動=1,老異動價,0,1,2),COLORGREEN,LINETHICK2;DRAWSL(PERIOD=5AND時間=1AND深圳股=1AND第五次異動=1AND新異動A>19.99,新異動價A,0,1,2),COLORGREEN,LINETHICK2;DRAWTEXT(PERIOD=5AND深圳股=1AND第六次異動=1,L,'第六次異動'),COLORYELLOW;DRAWSL(PERIOD=5AND時間=0AND深圳股=1AND第六次異動=1,老異動價,0,1,2),COLORGREEN,LINETHICK2;DRAWSL(PERIOD=5AND時間=1AND深圳股=1AND第六次異動=1AND新異動A>19.99,新異動價A,0,1,2),COLORGREEN,LINETHICK2;DRAWSL(PERIOD=5AND時間=1AND深圳股=1ANDEXISTR(異動=1,2,1)=0AND漲停價>新異動價B,新異動價B,0,1,2),COLORWHITE,LINETHICK1;