P0:=MA(INDEXC,34);
P1:=(55*P0+34*REF(P0,1)+21*REF(P0,2)+13*REF(P0,3)+8*REF(P0,4)+5*REF(P0,5)
+3*REF(P0,6)+2*REF(P0,7)+REF(P0,8)+REF(P0,9))/143;
P2:=REF(P1,1);
大盘长牛熊:=0.5*(P1+P2);
H0:=MA(C,8);
H1:=(55*H0+34*REF(H0,1)+21*REF(H0,2)+13*REF(H0,3)+8*REF(H0,4)+5*REF(H0,5)
+3*REF(H0,6)+2*REF(H0,7)+REF(H0,8)+REF(H0,9))/143;
H2:=REF(H1,1);
短期牛熊:0.5*(H1+H2),NODRAW,COLORYELLOW;
DRAWBAND(H1,RGB(255,255,0),H2,RGB(0,0,255));
STICKLINE(H1 H2,H1,H2,10,0),COLORYELLOW;
I0:=MA(C,34);
I1:=(55*I0+34*REF(I0,1)+21*REF(I0,2)+13*REF(I0,3)+8*REF(I0,4)+5*REF(I0,5)
+3*REF(I0,6)+2*REF(I0,7)+REF(I0,8)+REF(I0,9))/143;
I2:=REF(I1,1);
长期牛熊:0.5*(I1+I2),NODRAW,COLORRED;
DRAWBAND(I1,RGB(255,0,0),I2,RGB(0,255,0));
STICKLINE(I1 I2,I1,I2,10,0),COLORRED;
差:100*(短期牛熊-长期牛熊)/长期牛熊,COLORMAGENTA,NODRAW;