VAR1:=ABS(CLOSE-REF(CLOSE,20));
VAR2:=SUM(ABS(CLOSE-REF(CLOSE,1)),20);
VAR3:=VAR1/VAR2;
VAR4:=VAR3*(0.8-2/8)+2/8;
VAR5:=VAR4*VAR4;
WENG:DMA(CLOSE,VAR5),COLORWHITE,LINETHICK1;
VAR6:=SUM(TR,20);
VAR7:=HHV(HIGH,20)-LLV(LOW,20);
VAR8:=VAR7/VAR6;
VAR9:=(VAR8/SUM(TR,20));
VAR10:=VAR9*CLOSE+(1-VAR9)*REF(WENG,1);
JIAN:EMA(VAR10,3),COLORYELLOW,LINETHICK2;
VAR18:=CROSS(WENG,JIAN) AND JIAN>REF(JIAN,1);
VAR16:=CROSS(CLOSE,JIAN) AND WENG>REF(WENG,1);
DRAWICON(VAR18 AND VAR16,LOW,9);