DRAWGBKLAST(CLOSE>0,STRIP(RGB(100,95,95),RGB(0,0,0),0));
DRAWTEXTREL(20,30,'宝塔镇河妖'),LINETHICK6,Coloryellow;
DRAWTEXTREL(200,30,STKLABEL+' '+STKNAME),LINETHICK6,ColorFFFF80;
VAR1:=MA(CLOSE,5);
VAR2:=MA(CLOSE,10);
VAR3:=MA(CLOSE,20);
VAR4:=MA(CLOSE,30);
VAR5:=MA(CLOSE,60);
F1:=VAR1>REF(VAR1,1);
F2:=VAR2>REF(VAR2,1);
F3:=VAR2>REF(VAR2,1);
F4:=VAR2>REF(VAR2,1);
F5:=VAR2>REF(VAR2,1);
Var2:=SMA(Var1,3,1);
Var3:=SMA(Var2,3,1);
Var4:=SMA(Var3,3,1);
cp:="cpzb@cp";
DRAWICON(cp=1,l*0.95,4),ALIGN1;
DRAWICON(cp=9,h*1.05,5),ALIGN1;
DRAWtext(cp=1,l*0.910,'买进'),coloryellow,ALIGN1;
DRAWtext(cp=9,h*1.075,'卖出'),colorgreen,ALIGN1;
PARTLINE(Var1,F1,RGB(255,0,0),1,RGB(0,255,0)),LINETHICK2;
PARTLINE(Var2,F2,RGB(255,0,0),1,RGB(0,255,0)),LINETHICK2;
PARTLINE(Var3,F3,RGB(255,0,0),1,RGB(0,255,0)),LINETHICK2;
PARTLINE(Var4,F3,RGB(255,0,0),1,RGB(0,255,0)),LINETHICK2;
PARTLINE(Var5,F3,RGB(255,0,0),1,RGB(0,255,0)),LINETHICK5;
B1:=REF(CLOSE,1);B2:=REF(CLOSE,2);B3:=REF(CLOSE,3);B4:=REF(CLOSE,4);
CMAX:=MAX(MAX(MAX(CLOSE,B1),B2),B3);CMIN:=MIN(MIN(MIN(CLOSE,B1),B2),B3);
STICKLINE(CLOSE=CMAX AND (B1>=B2 OR B1>=B3) OR B1=CMAX AND (B2=CMIN OR B3=CMIN) AND CLOSE>=B2 OR
B2=CMAX AND B3=CMIN AND CLOSE>=B1 OR B3=CMAX AND CLOSE>=B1 AND CLOSE>=B2,B1,CLOSE,8.2,0),COLOR000055;
STICKLINE(CLOSE=CMAX AND (B1>=B2 OR B1>=B3) OR B1=CMAX AND (B2=CMIN OR B3=CMIN) AND CLOSE>=B2 OR
B2=CMAX AND B3=CMIN AND CLOSE>=B1 OR B3=CMAX AND CLOSE>=B1 AND CLOSE>=B2,B1,CLOSE,7.7,0),COLOR000077;
STICKLINE(CLOSE=CMAX AND (B1>=B2 OR B1>=B3) OR B1=CMAX AND (B2=CMIN OR B3=CMIN) AND CLOSE>=B2 OR
B2=CMAX AND B3=CMIN AND CLOSE>=B1 OR B3=CMAX AND CLOSE>=B1 AND CLOSE>=B2,B1,CLOSE,5.1,0),COLOR000099;
STICKLINE(CLOSE=CMAX AND (B1>=B2 OR B1>=B3) OR B1=CMAX AND (B2=CMIN OR B3=CMIN) AND CLOSE>=B2 OR
B2=CMAX AND B3=CMIN AND CLOSE>=B1 OR B3=CMAX AND CLOSE>=B1 AND CLOSE>=B2,B1,CLOSE,3.5,0),COLOR0000BB;
STICKLINE(CLOSE=CMAX AND (B1>=B2 OR B1>=B3) OR B1=CMAX AND (B2=CMIN OR B3=CMIN) AND CLOSE>=B2 OR
B2=CMAX AND B3=CMIN AND CLOSE>=B1 OR B3=CMAX AND CLOSE>=B1 AND CLOSE>=B2,B1,CLOSE,1.9,0),COLOR0000EE;
STICKLINE(CLOSE=CMAX AND (B1>=B2 OR B1>=B3) OR B1=CMAX AND (B2=CMIN OR B3=CMIN) AND CLOSE>=B2 OR
B2=CMAX AND B3=CMIN AND CLOSE>=B1 OR B3=CMAX AND CLOSE>=B1 AND CLOSE>=B2,B1,CLOSE,0.3,0),COLOR0000FF;
STICKLINE(CLOSE=CMAX AND B1=CMIN,B2,CLOSE,8.2,0),COLOR555555;
STICKLINE(CLOSE=CMAX AND B1=CMIN,B2,CLOSE,7.7,0),COLOR777777;
STICKLINE(CLOSE=CMAX AND B1=CMIN,B2,CLOSE,5.1,0),COLOR999999;
STICKLINE(CLOSE=CMAX AND B1=CMIN,B2,CLOSE,3.5,0),COLORBBBBBB;
STICKLINE(CLOSE=CMAX AND B1=CMIN,B2,CLOSE,1.9,0),COLORDDDDDD;
STICKLINE(CLOSE=CMAX AND B1=CMIN,B2,CLOSE,0.3,0),COLORFFFFFF;
STICKLINE(CLOSE=CMIN AND (B1
STICKLINE(B1=CMAX AND CLOSE=CMIN,B2,CLOSE,7.7,0),COLOR007700;
STICKLINE(B1=CMAX AND CLOSE=CMIN,B2,CLOSE,5.1,0),COLOR009900;
STICKLINE(B1=CMAX AND CLOSE=CMIN,B2,CLOSE,3.5,0),COLOR00BB00;
STICKLINE(B1=CMAX AND CLOSE=CMIN,B2,CLOSE,1.9,0),COLOR00EE00;
STICKLINE(B1=CMAX AND CLOSE=CMIN,B2,CLOSE,0.3,0),COLOR00FF00;
STICKLINE(B1=CMIN AND CLOSE>=B2 OR (B2=CMIN AND B1<=B3 OR
B3=CMIN AND B1<=B2) AND B2
STICKLINE(B1=CMIN AND CLOSE>=B2 OR (B2=CMIN AND B1<=B3 OR
B3=CMIN AND B1<=B2) AND B2
STICKLINE(B1=CMIN AND CLOSE>=B2 OR (B2=CMIN AND B1<=B3 OR
B3=CMIN AND B1<=B2) AND B2
STICKLINE(B1=CMIN AND CLOSE>=B2 OR (B2=CMIN AND B1<=B3 OR
B3=CMIN AND B1<=B2) AND B2
STICKLINE(B1=CMIN AND CLOSE>=B2 OR (B2=CMIN AND B1<=B3 OR
B3=CMIN AND B1<=B2) AND B2
STICKLINE(B1=CMIN AND CLOSE>=B2 OR (B2=CMIN AND B1<=B3 OR
B3=CMIN AND B1<=B2) AND B2
STICKLINE(B1=CMAX AND CLOSE
B3=CMAX AND B1>B2) AND B2>=B4 AND CLOSE
B3=CMAX AND B1>B2) AND B2>=B4 AND CLOSE
B3=CMAX AND B1>B2) AND B2>=B4 AND CLOSE
B3=CMAX AND B1>B2) AND B2>=B4 AND CLOSE
B3=CMAX AND B1>B2) AND B2>=B4 AND CLOSE
B3=CMAX AND B1>B2) AND B2>=B4 AND CLOSE