O1:=(SUM(EMA((CLOSE+LOW)/2,1)/3,3)),COLOR00FFFF,LINETHICK1;
O2:=EMA(O1,3),COLORFF00FF,LINETHICK1;
O3:=EMA(O2,3),COLOR00FF00,LINETHICK1;
MMM:MA(CLOSE,20),LINETHICK2,COLOR00FF00;
IF(MMM>REF(MMM,1),MMM,DRAWNULL)COLORRED,LINETHICK2;
IF(MMM<REF(MMM,1),MMM,DRAWNULL)COLOR00FF00,LINETHICK2;
VAR1:=CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2);
VAR2:=REF(VAR1,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR3:=REF(VAR2,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR4:=REF(VAR3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR5:=REF(VAR4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR6:=REF(VAR5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR7:=REF(VAR6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR8:=REF(VAR7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR9:=REF(VAR8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARA:=REF(VAR9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VARB:=REF(VARA,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARC:=REF(VARB,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
X3:=EMA(CLOSE,30);
STICKLINE(((C >= X3) AND (C >= O)),H,L,0,1),COLOR0000AA;
STICKLINE(((C >= X3) AND (C >= O)),O,C,3,0),COLOR0000AA;
STICKLINE(((C >= X3) AND (C >= O)),O,C,2.3,0),COLOR0000CC;
STICKLINE(((C >= X3) AND (C >= O)),O,C,1.8,0),COLOR0000FF;
STICKLINE(((C >= X3) AND (C >= O)),O,C,0.1,0),COLORCC66FF;
STICKLINE(((C >= X3) AND (C <= O)),H,L,0,1),COLOR0000AA;
STICKLINE(((C >= X3) AND (C <= O)),O,C,3,0),COLOR0000AA;
STICKLINE(((C >= X3) AND (C <= O)),O,C,2.3,0),COLOR0000CC;
STICKLINE(((C >= X3) AND (C <= O)),O,C,1.8,0),COLOR0000FF;
STICKLINE(((C >= X3) AND (C <= O)),O,C,0.1,0),COLORCC66FF;
STICKLINE(((C <= X3) AND (C >= O)),H,L,0,1),COLORFF6600;
STICKLINE(((C <= X3) AND (C >= O)),O,C,3,0),COLORFF6600;
STICKLINE(((C <= X3) AND (C >= O)),O,C,2.3,0),COLORFF9900;
STICKLINE(((C <= X3) AND (C >= O)),O,C,1.8,0),COLORFFCC00;
STICKLINE(((C <= X3) AND (C >= O)),O,C,0.1,0),COLORFFFF00;
STICKLINE(((C <= X3) AND (C <= O)),H,L,0,0),COLORFF6600;
STICKLINE(((C <= X3) AND (C <= O)),O,C,3,0),COLORFF6600;
STICKLINE(((C <= X3) AND (C <= O)),O,C,2.3,0),COLORFF9900;
STICKLINE(((C <= X3) AND (C <= O)),O,C,1.8,0),COLORFFCC00;
STICKLINE(((C <= X3) AND (C <= O)),O,C,0.1,0),COLORFFFF00;
VARD:=CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2);
VARE:=REF(VARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2),COLOR0000AA;
VARF:=REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2),COLORRED;
VAR10:=REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2),COLOR0000AA;
VAR11:=REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2),COLOR0000CC;
VAR12:=REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2),COLOR0000FF;
VAR13:=REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2),COLORFF0000;
VAR14:=REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2),COLOR0000FF;
VAR15:=REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2),COLORFF0000;
VAR16:=REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2),COLOR0000FF;
VAR17:=REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2),COLORFF3333;
VAR18:=REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2),COLOR0000FF;
VAR19:=REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR
VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1) AND VAR1;
VAR1A:=REF(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR
VAR8 OR VAR9 OR VARA OR VARB OR VARC,1) AND VARD;
DRAWTEXT(FILTER(VAR19=1,5),LOW*0.99,'进'),COLORFF00FF;
DRAWICON(FILTER(VAR19=1,5),LOW*0.992,9);
STICKLINE(FILTER(VAR19=1,5),O,C,3,0),COLORYELLOW;
DRAWTEXT(FILTER(VAR1A=1,5),HIGH*1.01,'出'),COLOR00FF00;
DRAWICON(FILTER(VAR1A=1,5),HIGH*1.005,15);
STICKLINE(FILTER(VAR1A=1,5),O,C,3,0),COLORGREEN;