TOTAL:=IF(PERIOD=1,5,IF(PERIOD=2,15,IF(PERIOD=3,30,IF(PERIOD=4,60,IF(PERIOD=5,240,1)))));
MTIME:=MOD(FROMOPEN,TOTAL);
CTIME:=IF(MTIME 0.5,TOTAL,MTIME);
V1:IF(CURRBARSCOUNT=1,V*TOTAL/CTIME,V),NODRAW;
STICKLINE(CURRBARSCOUNT=1 (SETCODE=0 || SETCODE=1),V1,0,-1,-1),COLOR00C0C0;
量:V,VOLSTICK;
放量:IF(V1/REF(VOL,1) 1.5,INTPART(V1/REF(VOL,1)+0.5),0);
放量1:IF(放量 0,REF(VOL,1),DRAWNULL);
放量2:IF(放量 0,REF(VOL,1)*2,DRAWNULL);
放量3:IF(放量 2,REF(VOL,1)*3,DRAWNULL);
DRAWTEXT(放量 0,放量1,'-1-');
DRAWTEXT(放量 0,放量2,'-2-');
DRAWTEXT(放量 =3,放量3,'-3-');
起点1:=CONST(SUMBARS(V/REF(V,1) =2,1));
起点2:=CONST(SUMBARS(V/REF(V,1) =2,2));
起点3:=CONST(SUMBARS(V/REF(V,1) =2,3));
起点4:=CONST(SUMBARS(V/REF(V,1) =2,4));
起点5:=CONST(SUMBARS(V/REF(V,1) =2,5));
线1:IF(起点1 =CURRBARSCOUNT,CONST(REF(V,起点1-1)),DRAWNULL),COLORLIGREEN;
线2:IF(起点2 =CURRBARSCOUNT,CONST(REF(V,起点2-1)),DRAWNULL),COLORLIGREEN;
线3:IF(起点3 =CURRBARSCOUNT,CONST(REF(V,起点3-1)),DRAWNULL),COLORLIGREEN;
线4:IF(起点4 =CURRBARSCOUNT,CONST(REF(V,起点4-1)),DRAWNULL),COLORLIGREEN;
线5:IF(起点5 =CURRBARSCOUNT,CONST(REF(V,起点5-1)),DRAWNULL),COLORLIGREEN;