A:=SYSPARAM(1)=BARPOS;
VERTLINE(A=1),Color00FFFF;
a0:=BARSCOUNT(c);
a2:=SYSPARAM(2);
a3:=SYSPARAM(3);
a4:=SYSPARAM(4);
a5:=SYSPARAM(5);
nn0:=a3-a2;
nn:=a0-a2;
hh1:=(a4-a5)/20;
y0:=a0>=a2;
vv0:=if(y0=1 and SYSPARAM(1)>=a0,v,0);
c1:=if(BETWEEN(c,a4-0*hh1,a4-1*hh1),vv0,0);
c2:=if(BETWEEN(c,a4-1*hh1,a4-2*hh1),vv0,0);
c3:=if(BETWEEN(c,a4-2*hh1,a4-3*hh1),vv0,0);
c4:=if(BETWEEN(c,a4-3*hh1,a4-4*hh1),vv0,0);
c5:=if(BETWEEN(c,a4-4*hh1,a4-5*hh1),vv0,0);
c6:=if(BETWEEN(c,a4-5*hh1,a4-6*hh1),vv0,0);
c7:=if(BETWEEN(c,a4-6*hh1,a4-7*hh1),vv0,0);
c8:=if(BETWEEN(c,a4-7*hh1,a4-8*hh1),vv0,0);
c9:=if(BETWEEN(c,a4-8*hh1,a4-9*hh1),vv0,0);
c10:=if(BETWEEN(c,a4-9*hh1,a4-10*hh1),vv0,0);
c11:=if(BETWEEN(c,a4-10*hh1,a4-11*hh1),vv0,0);
c12:=if(BETWEEN(c,a4-11*hh1,a4-12*hh1),vv0,0);
c13:=if(BETWEEN(c,a4-12*hh1,a4-13*hh1),vv0,0);
c14:=if(BETWEEN(c,a4-13*hh1,a4-14*hh1),vv0,0);
c15:=if(BETWEEN(c,a4-14*hh1,a4-15*hh1),vv0,0);
c16:=if(BETWEEN(c,a4-15*hh1,a4-16*hh1),vv0,0);
c17:=if(BETWEEN(c,a4-16*hh1,a4-17*hh1),vv0,0);
c18:=if(BETWEEN(c,a4-17*hh1,a4-18*hh1),vv0,0);
c19:=if(BETWEEN(c,a4-18*hh1,a4-19*hh1),vv0,0);
c20:=if(BETWEEN(c,a4-19*hh1,a4-20*hh1),vv0,0);
v1:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c1,nn0),0),2));
v2:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c2,nn0),0),2));
v3:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c3,nn0),0),2));
v4:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c4,nn0),0),2));
v5:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c5,nn0),0),2));
v6:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c6,nn0),0),2));
v7:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c7,nn0),0),2));
v8:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c8,nn0),0),2));
v9:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c9,nn0),0),2));
v10:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c10,nn0),0),2));
v11:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c11,nn0),0),2));
v12:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c12,nn0),0),2));
v13:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c13,nn0),0),2));
v14:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c14,nn0),0),2));
v15:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c15,nn0),0),2));
v16:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c16,nn0),0),2));
v17:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c17,nn0),0),2));
v18:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c18,nn0),0),2));
v19:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c19,nn0),0),2));
v20:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c20,nn0),0),2));
av0:=max(v1,max(v2,max(v3,max(v4,max(v5,max(v6,max(v7,max(v8,max(v9,max(v10,
max(v11,max(v12,max(v13,max(v14,max(v15,max(v16,max(v17,max(v18,max(v19,v20)))))))))))))))))));
FILLRGN(v1/av0>=nn/nn0 and nn>=0,a4-0*hh1,a4-1*hh1+0.05),colormagenta;
FILLRGN(v2/av0>=nn/nn0 and nn>=0,a4-1*hh1,a4-2*hh1+0.05),colormagenta;
FILLRGN(v3/av0>=nn/nn0 and nn>=0,a4-2*hh1,a4-3*hh1+0.05),colormagenta;
FILLRGN(v4/av0>=nn/nn0 and nn>=0,a4-3*hh1,a4-4*hh1+0.05),colormagenta;
FILLRGN(v5/av0>=nn/nn0 and nn>=0,a4-4*hh1,a4-5*hh1+0.05),colormagenta;
FILLRGN(v6/av0>=nn/nn0 and nn>=0,a4-5*hh1,a4-6*hh1+0.05),colormagenta;
FILLRGN(v7/av0>=nn/nn0 and nn>=0,a4-6*hh1,a4-7*hh1+0.05),colormagenta;
FILLRGN(v8/av0>=nn/nn0 and nn>=0,a4-7*hh1,a4-8*hh1+0.05),colormagenta;
FILLRGN(v9/av0>=nn/nn0 and nn>=0,a4-8*hh1,a4-9*hh1+0.05),colormagenta;
FILLRGN(v10/av0>=nn/nn0 and nn>=0,a4-9*hh1,a4-10*hh1+0.05),colormagenta;
FILLRGN(v11/av0>=nn/nn0 and nn>=0,a4-10*hh1,a4-11*hh1+0.05),colormagenta;
FILLRGN(v12/av0>=nn/nn0 and nn>=0,a4-11*hh1,a4-12*hh1+0.05),colormagenta;
FILLRGN(v13/av0>=nn/nn0 and nn>=0,a4-12*hh1,a4-13*hh1+0.05),colormagenta;
FILLRGN(v14/av0>=nn/nn0 and nn>=0,a4-13*hh1,a4-14*hh1+0.05),colormagenta;
FILLRGN(v15/av0>=nn/nn0 and nn>=0,a4-14*hh1,a4-15*hh1+0.05),colormagenta;
FILLRGN(v16/av0>=nn/nn0 and nn>=0,a4-15*hh1,a4-16*hh1+0.05),colormagenta;
FILLRGN(v17/av0>=nn/nn0 and nn>=0,a4-16*hh1,a4-17*hh1+0.05),colormagenta;
FILLRGN(v18/av0>=nn/nn0 and nn>=0,a4-17*hh1,a4-18*hh1+0.05),colormagenta;
FILLRGN(v19/av0>=nn/nn0 and nn>=0,a4-18*hh1,a4-19*hh1+0.05),colormagenta;
FILLRGN(v20/av0>=nn/nn0 and nn>=0,a4-19*hh1,a4-20*hh1+0.05),colormagenta;
a4-N*hh1,POINTDOT,PRECISION2;
//飞狐季度末画竖线
z:=BARSLAST(DAY<ref(day,1));
b:=BACKSET(z=0,z+2);
m:=month=3 or month=6 or month=9 or month=12;
VERTLINE(cross(b,0.5) and m);//飞狐季度末画竖线
AC:=C;
AH:=H;
AL:=L;
AO:=O;
STICKLINE(AC>=AO,AH,AC,1,0),colorblue;
STICKLINE(AC>=AO,Ao,Al,1,0),colorblue;
STICKLINE(AC>=AO,AO,Ac,8,1),colorblue;
STICKLINE(AC<=AO,AO,Ac,8,0),colorblue;
STICKLINE(AC<=AO,Ah,Ao,1,0),colorblue;
STICKLINE(AC<=AO,AO,Al,1,0),colorblue;
VAR1:=EMA(CLOSE,3);
VAR2:=EMA(CLOSE,8);
MA21:=EMA(CLOSE,21);
A1:=(((EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),3) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),6)) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),9)) / 3);
A2:=(((EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),5) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),10)) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),20)) / 3);
A3:=(((EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),7) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),14)) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),28)) / 3);
A4:=(((EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),9) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),18)) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),36)) / 3);
A5:=(((EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),11) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),22)) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),44)) / 3);
A6:=(((EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),13) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),26)) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),52)) / 3);
A:(((EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),21) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),34)) + EMA(((((OPEN + HIGH) + LOW) + CLOSE) / 4),55)) / 3);
PARTLINE((A1 > REF(A1,1)),A1),colorFF00FF;
PARTLINE((A1 < REF(A1,1)),A1),colorFF00;
PARTLINE((A2 > REF(A2,1)),A2),colorFF00FF;
PARTLINE((A2 < REF(A2,1)),A2),colorFF00;
PARTLINE((A3 > REF(A3,1)),A3),colorFF00FF;
PARTLINE((A3 < REF(A3,1)),A3),colorFF00;
PARTLINE((A4 > REF(A4,1)),A4),colorFF00FF;
PARTLINE((A4 < REF(A4,1)),A4),colorFF00;
PARTLINE((A5 > REF(A5,1)),A5),colorFF00FF;
PARTLINE((A5 < REF(A5,1)),A5),colorFF00;
PARTLINE((A6 > REF(A6,1)),A6),colorFF00FF;
PARTLINE((A6 < REF(A6,1)),A6),colorFF00;
PARTLINE((A > REF(A,1)),A),LINETHICK3,colorFF00FF;
PARTLINE((A < REF(A,1)),A),LINETHICK3,colorFF00; |