VAR1:=MAX(DYNAINFO(3),DYNAINFO(5));
VAR2:=MIN(DYNAINFO(3),DYNAINFO(6));
VAR3:=VAR1-VAR2;
VAR4:=(EMA(CLOSE,12)-EMA(CLOSE,26))+DYNAINFO(3);
VAR5:=EMA(VAR4,9);
VAR6:=10*(VAR4-VAR5);
VAR7:=EMA(VAR6,2);
VAR8:=SUM(AMOUNT,BARSCOUNT(CLOSE))/SUM(V*100,BARSCOUNT(CLOSE));
VAR9:=EXPMA(CLOSE/VAR8,20);
VAR10:=YEAR AND MONTH AND DAY;
VAR11:=STRCAT(CON2STR(YEAR,0),'年');
VAR12:=STRCAT(CON2STR(MONTH,0),'月');
VAR13:=STRCAT(CON2STR(DAY,0),'日');
VAR14:=STRCAT('星期',IF(WEEKDAY=1,'一',IF(WEEKDAY=2,'二',IF(WEEKDAY=3,'三',IF(WEEKDAY=4,'四',IF(WEEKDAY=5,'五',IF(WEEKDAY=6,'六','日')))))));
VAR15:=STRCAT(STRCAT(STRCAT(VAR11,VAR12),STRCAT(VAR13,VAR14)),'');
VAR16:=V*C/100;
VAR17:=SUM((IF(((VAR16/8>20) AND (CLOSE>(REF(CLOSE,1)))),VAR16,0)),0);
VAR18:=SUM((IF(((VAR16/8>20) AND (CLOSE<(REF(CLOSE,1)))),VAR16,0)),0);
VAR26:=SUM((IF(((VAR16/8<20) AND (CLOSE>(REF(CLOSE,1)))),VAR16,0)),0);
VAR28:=SUM((IF(((VAR16/8<20) AND (CLOSE<(REF(CLOSE,1)))),VAR16,0)),0);
XG:HHV(H,480),DOTLINE,COLORCYAN;
阻力:VAR2+VAR3*8/9,COLORLIRED,DOTLINE;
支撑:VAR2+VAR3*0.5/9,COLORGREEN,DOTLINE;
均线:IF(BETWEEN(C/(SUM(AMOUNT,0)/SUM(VOL*100,0)),1.05,0.95)=0,MA(C,0),(SUM(AMOUNT,0)/SUM(VOL*100,0))),COLORYELLOW,DOTLINE;
STICKLINE(VAR6>=VAR7 AND VAR6>=0,DYNAINFO(3),VAR6+DYNAINFO(3),0,-1),COLORLIGRAY;
STICKLINE(VAR6<VAR7 AND VAR6>0,DYNAINFO(3),VAR6+DYNAINFO(3),0,-1),COLORLICYAN;
STICKLINE(VAR6>=VAR7 AND VAR6<0,DYNAINFO(3),VAR6+DYNAINFO(3),0,-1),COLORLIGRAY;
STICKLINE(VAR6<VAR7 AND VAR6<0,DYNAINFO(3),VAR6+DYNAINFO(3),0,-1),COLORLIGREEN;
DRAWTEXT(CROSS(VAR9,1.02),C*0.999,' 拉'),COLORMAGENTA;
DRAWICON(CROSS(VAR9,1.04),C,45);
DRAWTEXT(CROSS(VAR9,1.04),C*0.999,' 冲'),COLORRED;
DRAWTEXT(LONGCROSS(支撑,C,2),C-0.01,' 买入'),COLOR0000FF;
DRAWICON(LONGCROSS(支撑,C,2),C-0.01,1);
STICKLINE(LONGCROSS(支撑,C,2),C,阻力,0,-1),COLORCYAN;
DRAWTEXT(LONGCROSS(C,阻力,2),C+0.01,' 卖出'),COLORGREEN;
DRAWICON(LONGCROSS(C,阻力,2),C+0.01,45);
STICKLINE(LONGCROSS(C,阻力,2),C,支撑,0,-1),COLORRED;
DRAWTEXT_FIX(VAR10,0.905,0,0,VAR15),COLORGRAY;
DRAWTEXT_FIX(1,0.752,1-0.088,0,STRCAT(STRCAT('【机构买盘】',CON2STR(VAR17,2)),' 万')),COLORRED;
DRAWTEXT_FIX(1,0.752,1-0.001,0,STRCAT(STRCAT('【机构卖盘】',CON2STR(VAR18,2)),' 万')),COLORGREEN;
DRAWTEXT_FIX(1,0.883,1-0.088,0,STRCAT(STRCAT('【散户买盘】',CON2STR(VAR26,2)),' 万')),COLORMAGENTA;
DRAWTEXT_FIX(1,0.883,1-0.001,0,STRCAT(STRCAT('【散户卖盘】',CON2STR(VAR28,2)),' 万')),COLORCYAN;