S:=FROMNIGHT;
VAMOUNT:=IF(s=0 AND FROMOPEN>1,AMOUNT*241/FROMOPEN,AMOUNT);
VAR1:SMA(VAMOUNT,10,1)/100000000,colorred,LINETHICK1;
VAR2:=REF(VAR1,1);
STICKLINE(VAR1>VAR2,VAR1,VAR2,8,0),colorred;
STICKLINE(VAR1< VAR2,VAR1,VAR2,8,0),colorgreen;
HI:HHV(VAR1,N),colorblue,LINETHICK1;
LO:LLV(VAR1,M),colorcyan,LINETHICK1;
VV:(HI+LO)/2,coloryellow,LINETHICK1;