N:=20;
GOQIRI:=2012120199;
GOQI:=DATE>=GOQIRI-19000000;
GOQIVU:=COUNT(GOQI=1,0);
TIVIQI:=GOQI=1 AND DAY>=1 AND DAY<=15 AND MOD(MONTH,2)=MOD(INTPART(GOQIRI/100),2);
TIVIDJ:=GOQIVU=1 OR TIVIQI>REF(TIVIQI,1);
TIVI:=TIVIDJ=1 AND COUNT(TIVIDJ=1,20)<2 AND CURRBARSCOUNT<=20 AND FROMOPEN>60;
BBLT:=BArslAST(TIVI=1)>=5;
WUXD:=GOQI=1 AND BBLT=1;
DPC0:=MA(INDEXC,2*N);
DPC1:=(INDEXC-DPC0)/DPC0*100;
DPC2:=IF(INDEXC>0,EMA(DPC1,N),DRAWNULL);
DPC3:=IF(INDEXC>0,EMA(DPC2,N/2),DRAWNULL);
大盘强弱1:=DPC3;
GGC0:=MA(CLOSE,2*N);
GGC1:=(CLOSE-GGC0)/GGC0*100;
GGC2:=EMA(GGC1,N);
GGC3:=EMA(GGC2,N/2);
个股强弱1:=GGC3;
相对强弱1:=个股强弱1-大盘强弱1;
涨幅1:=GGC2;
涨势1:=EMA(GGC2-GGC3,N/4)*2;
大盘强弱:IF(WUXD,DRAWNULL,大盘强弱1),COLORFF4040;
个股强弱:IF(WUXD,DRAWNULL,个股强弱1),COLOR00FFFF;
相对强弱:IF(WUXD,DRAWNULL,相对强弱1),COLORSTICK,COLOR4040FF;
涨幅:IF(WUXD,DRAWNULL,涨幅1),COLORFFFFFF;
涨势:IF(WUXD,DRAWNULL,涨势1),COLOR888888;