N:=5;
AMV0:=vol*(O+C+H+L)/4;
势:EMA(AMV0,21)/EMA(VOL,21)COLORFFFFCC,LINETHICK2;
压:6*HHV(势,2)-5*势,COLOR00FF33,LINETHICK2;
托:2*势-压,COLORRED,LINETHICK2;
VAR1:=DATE>900101 AND DATE<2098108;
M1:=MA(C,5);{短期参数:5}
M2:=MA(C,10);{中期参数:10}
M3:=MA(C,30);{长期参数:30}
{以下计算交叉点距今的天数}
D1:=BArslAST(crOSS(M1,M2));{短上穿中}
D2:=BARSLAST(CROSS(M1,M3));{短上穿长}
D3:=BARSLAST(CROSS(M2,M3));{中上穿长}
T1:=CROSS(M2,M3);{今天中线上穿长线}
T2:=D1>=D2 AND D2>=D3;{交叉按指定的先后出现}
T3:=COUNT(CROSS(M2,M1) OR CROSS(M3,M2) OR CROSS(M3,M1),D1)=0;{中间无夹杂其它交叉}
T4:=REF(M1<M3 AND M2<M3,D1+1);{短上穿中前一天短、中线在长线之下}
突破:=T1 AND T2 AND T3 AND T4;{价托确定};
获利盘90均线:EMA(COST(90),N),COLORLIBLUE,LINETHICK2;
获利盘30均线:EMA(COST(30),N),COLOR00FFFF,LINETHICK2;
DRAWICON(CROSS(zig(3,13),REF(ZIG(3,13),1))*VAR1,LOW-0.1,1);
DRAWICON(CROSS(REF(ZIG(3,13),1),ZIG(3,13))*VAR1,HIGH+0.05,2);
DRAWICON(CROSS(PWINNER(14,CLOSE),0.9) AND LWINNER(5,CLOSE)>0.9,HIGH+0.05,5);
DRAWTEXT(突破>0,LOW,'▲突破▲'),COLORLIBLUE;