MID:=(3*CLOSE+LOW+OPEN+HIGH)/6;
MA1:MA(MID,4),COLORYELLOW;
MA2:MA(MID,9),COLORRED;
MA3:MA(MID,13),COLORFFCC66;
MA4:MA(MID,21),COLORGREEN;
MA55:MA(MID,55),LINETHICK1;
乖离线:=((C-REF(MA1,1))/20+MA1)*1.20;
VAR1:=crOSS(MA1,MA2) AND CROSS(MA1,MA3) AND V>REF(V,1);
VAR2:=MA1>REF(MA1,2) AND V>REF(V,1) AND CROSS(C,MA1);
VAR3:=EMA(100-(100/(1+SUM(IF(MID>REF(MID,1),MID*vol,0),14)/SUM
(IF(MID
VAR4:=DRAWLINE(VAR3>=HHV(VAR3,4),VAR3,VAR3<=LLV(VAR3,4),VAR3,1);
VAR5:=VAR3=VAR4;
VAR6:=VAR3
VAR7:=(((MID - MA(MID,6))/(MA(MID,6)))*(200) + ((MID - MA(MID,24))/(MA(MID,24)))*(200) + ((MID - MA(MID,32))/(MA(MID,32)))*(200))/(3);
VAR8:=MA2>=REF(MA2,1) AND CROSS(C,MA1) AND CROSS(C,MA2) AND V>REF(V,1);
VAR9:=VAR5 AND VAR6;
VAR10:=VAR2 OR VAR8 OR VAR9;
STICKLINE(VAR1,L,L-0.09,4,0),COLORYELLOW;
DRAWTEXT(VAR1,L-0.13,'金叉'),COLORYELLOW;
STICKLINE(CROSS(C,MA2) AND CROSS(C,MA3) AND CROSS(C,MA1),L,L-0.09,4,0),COLORYELLOW;
DRAWTEXT(CROSS(C,MA2) AND CROSS(C,MA3) AND CROSS(C,MA1),L-0.13,'并线开花'),COLORYELLOW;
STICKLINE(CROSS(C,乖离线),H,H+0.09,4,0),COLOR00FF00;
DRAWTEXT(CROSS(C,乖离线) ,H+0.13,'卖点(打点停板不卖)'),COLOR00FF00;
STICKLINE(MA3>=REF(MA3,1) AND MA1>=REF(MA1,1) AND CROSS(C,MA3),L,L-0.09,4,0),COLORFFCC66;
DRAWTEXT(MA3>=REF(MA3,1) AND MA1>=REF(MA1,1) AND CROSS(C,MA3),L-0.13,'牛象'),COLORRED;
STICKLINE(VAR10 AND REF(NOT(VAR10),1),O,O*1.01,2,0),COLORYELLOW;
DRAWICON(VAR10 AND REF(NOT(VAR10),1),L,1);
DRAWICON((VAR7 > 20) AND FILTER((VAR7 < REF(VAR7,1)),5),(HIGH)*(1.02),2),COLORGREEN;