MID:=(3*CLOSE+LOW+OPEN+HIGH)/6;
安全A:MA((20*MID+19*REF(MID,1)+18*REF(MID,2)+17*REF(MID,3)+16*REF(MID,4)+15*REF(MID,5)+14*REF(MID,6)+13*REF(MID,7)+12*REF(MID,8)+11*REF(MID,9)+10*REF(MID,10)+9*REF(MID,11)+8*REF(MID,12)+7*REF(MID,13)+6*REF(MID,14)+5*REF(MID,15)+4*REF(MID,16)+3*REF(MID,17)+2*REF(MID,18)+REF(MID,20))/210,3),LINETHICK2,COLORWHITE;
PARTLINE(安全A REF(安全A,1),安全A),COLORWHITE,LINETHICK2;
PARTLINE(安全A REF(安全A,1),安全A),COLORGRAY,LINETHICK2;
买线:=EMA(CLOSE,2);
卖线:=EMA(((SLOPE(CLOSE,21) * 20) + CLOSE),42);
R:=MA(MID,17)+MA(MID,17)-REF(MA(MID,17),1);
XQ:=IF(MA(MID,17) R,R,MA(MID,17));
PARTLINE(XQ-(EMA(MID,3)-XQ) 安全A,XQ-(EMA(MID,3)-XQ)),COLORFF8080,LINETHICK2;
PARTLINE(XQ-(EMA(MID,3)-XQ) 安全A,XQ-(EMA(MID,3)-XQ)),COLORRED,LINETHICK2;
B36:=MA(CLOSE,3) - MA(CLOSE,6);
B612:=MA(CLOSE,6) - MA(CLOSE,12);
J:=((B36)/(CLOSE))*(10);
J1:=((B612)/(CLOSE))*(10);
DRAWTEXT((J (-0.2)) AND (J1 (-0.2)) AND CROSS(J,J1) ,(LOW)*(0.95),'●大牛'),COLORRED;
VAR111:=(((CLOSE - MA(CLOSE,6))/(MA(CLOSE,6)))*(200) + ((CLOSE - MA(CLOSE,24))/(MA(CLOSE,24)))*(200) + ((CLOSE - MA(CLOSE,32))/(MA(CLOSE,32)))*(200))/(3);
DRAWTEXT((VAR111 20) AND FILTER((VAR111 REF(VAR111,1)),5),(HIGH)*(1.02),'跑'),COLOR00FF00;
VAR9:=((CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27)))*(100);
VAR10:=SMA(VAR9,3,1);
VAR11:=SMA(VAR10,3,1);
VAR12:=SMA(VAR11,3,1);
DRAWTEXT((CROSS(VAR11,VAR12) AND (VAR11 40)),LOW * 0.98,'金叉'),COLORYELLOW;
BBUY:=CROSS(买线,卖线);
SEL:=CROSS(卖线,买线);
DRAWICON(CROSS(CLOSE,安全A) ,CLOSE,3);
DRAWICON(CROSS(XQ-(EMA(MID,3)-XQ),安全A),CLOSE,2);
DRAWICON(CROSS(安全A,XQ-(EMA(MID,3)-XQ)),CLOSE,1);
QW1:=(HIGH+LOW+CLOSE*2)/4;
QW3:=EMA(QW1,10);
QW4:=STD(QW1,10);
QW5:=(QW1-QW3)*100/QW4;
QW6:=EMA(QW5,5);
涨:=EMA(QW6,10)+100/2-5;
跌:=EMA(涨,4);
风险:PARTLINE(涨 160,LLV(LOW,21)),COLORYELLOW,CIRCLEDOT;
高危:PARTLINE(涨 180,LLV(LOW,21)),COLORRED,CIRCLEDOT;
DRAWTEXT(涨 160 AND REF(涨,1) 160,LOW * 0.90,'风险区'),COLORYELLOW;
DRAWTEXT(涨 180 AND REF(涨,1) 180,LOW * 0.92,'高危区'),COLORWHITE;