VAR1:=MA(VOL,5);
VAR2:=MA(VOL,40);
VAR3:=V*100/CAPITAL;
VAR4:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN));
VAR5:=IF(C>OPEN,VAR4*(HIGH-LOW),IF(C<OPEN,VAR4*((HIGH-OPEN)+(C-LOW)),VOL/2));
VAR6:=IF(C>OPEN,0-VAR4*((HIGH-C)+(OPEN-LOW)),IF(C<OPEN,0-VAR4*(HIGH-LOW),0-VOL/2));
VAR7:=HHV(V,90);
VAR8:=LLV(V,90);
VAR9:=VAR8+(VAR7-VAR8)*0.06;
VAR10:=VAR8+(VAR7-VAR8)*0.28;
VAR18:=VAR8+(VAR7-VAR8)*0.50;
VAR19:=VAR8+(VAR7-VAR8)*0.75;
VOLUME:VOL,VOLSTICK;
新股成交量:IF(BARSCOUNT(CLOSE)<40,VOL,DRAWNULL),VOLSTICK;
成交量(手):VOL,COLORWHITE,NODRAW;
调整周期:IF(VAR1<VAR2,BARSLAST(CROSS(VAR2,VAR1))+1,BARSLAST(CROSS(VAR2,VAR1))-BARSLAST(CROSS(VAR1,VAR2))),NODRAW;
调整总换手:IF(VAR1<VAR2,SUM(VAR3,BARSLAST(CROSS(VAR2,VAR1))+1),SUM(VAR3,BARSLAST(CROSS(VAR2,VAR1))+1)-SUM(VAR3,BARSLAST(CROSS(VAR1,VAR2))+1)),NODRAW;
调整均换手:调整总换手/调整周期,NODRAW;
虚拟成交量:IF(CURRBARSCOUNT=1 AND PERIOD=5,VOL*240/FROMOPEN,DRAWNULL),NODRAW;
放量上涨:C/REF(C,1)>=1.01 AND V/REF(V,1)>=1.5 AND V>MA(V,5) AND REF(V,1)/REF(MA(V,5),1)<=1.8,NODRAW;
STICKLINE(CURRBARSCOUNT=1 AND PERIOD=5,虚拟成交量,0,4,-1),COLOR00C0C0;
STICKLINE(VAR5>VAR6 AND VAR1>=VAR2,VOL,0,3,0),COLOR0000AA;
STICKLINE(VAR5>VAR6 AND VAR1>=VAR2,VAR5,0,2.5,0),COLOR0000BB;
STICKLINE(VAR5>VAR6 AND VAR1>=VAR2,VAR5,0,1.5,0),COLOR0000CC;
STICKLINE(VAR5>VAR6 AND VAR1>=VAR2,VAR5,0,1,0),COLOR0000EE;
STICKLINE(VAR6<VAR5 AND VAR1>=VAR2,VAR5,VAR5+ABS(VAR6),3,0),COLOR7B7B00;
STICKLINE(VAR6<VAR5 AND VAR1>=VAR2,VAR5,VAR5+ABS(VAR6),2.5,0),COLOR909000;
STICKLINE(VAR6<VAR5 AND VAR1>=VAR2,VAR5,VAR5+ABS(VAR6),1.5,0),COLORA8A800;
STICKLINE(VAR6<VAR5 AND VAR1>=VAR2,VAR5,VAR5+ABS(VAR6),1,0),COLORCECE00;
STICKLINE(VAR5>VAR6 AND VAR1<VAR2,0,VAR5,3,0),COLORRED;
STICKLINE(VAR5>VAR6 AND VAR1<VAR2,0,VAR5,2.5,0),COLOR0066FF;
STICKLINE(VAR5>VAR6 AND VAR1<VAR2,0,VAR5,1.5,0),COLOR0099FF;
STICKLINE(VAR5>VAR6 AND VAR1<VAR2,0,VAR5,1,0),COLORYELLOW;
STICKLINE(VAR6<VAR5 AND VAR1<VAR2,VAR5,VAR5+ABS(VAR6),3,0),COLOR007B00;
STICKLINE(VAR6<VAR5 AND VAR1<VAR2,VAR5,VAR5+ABS(VAR6),2.5,0),COLOR009000;
STICKLINE(VAR6<VAR5 AND VAR1<VAR2,VAR5,VAR5+ABS(VAR6),1.5,0),COLOR00A800;
【金】:REFDATE(VAR9,DATE),COLOR00FFFF;
【银】:REFDATE(VAR10,DATE),COLORFFFFFF;
【铜】:REFDATE(VAR18,DATE),COLORLIRED;
【铁】:REFDATE(VAR19,DATE),COLORRED;
【顶】:REFDATE(HHV(V,90),DATE),COLORCYAN;