Google
 

Trailing-Edge - PDP-10 Archives - BB-AI48A-BM - datatrieve/gigi/stacked_bar.cdd-plot
There are 3 other files named stacked_bar.cdd-plot in the archive. Click here to see a list.
{]&ie]ybc(0]:]*0],LLABEL 0]N]>0]@XALABEL ]\y \zYVALUEP ]] ]	YMXP \X] ]COLORP \]\\CNT \c\bJTEMP \i\hK \n\mKOUNT \G\sOFFSET \L\KBARY \R\QBARX \*\VBARBOTTOM \0\/YREF \6\4YLENGTH \;\:YMIN \A\@YMAX \\EYLABEL \\XREF \\XLENGTH \\XMIN \$\#XMAX \)XWIDTHaf]a]g]m]s 0]&]f0XLABEL 0]a]l0LABEL1 0]g]r0LABEL2 0]m]x0LABEL3
^^^^&^1^;^?^U^k/H^^t`9^HOUSEKEEP^0^ 0
^$L"X"8142241818244281^, 0
^.L"Y"8855225588552255^6 0
^9L"Z"1122448888442211^I^P]N^M00^SX^^f]^c00^u]g]&^y0]NV X 0\Zho]l X X`]s]&` X\`
!y\*`%"6@\`3"R`\0`B"5p`F0\\*\\0]a\A9`HLABEL

\Xa1]&a5aP\ia\iac 0c#ataybb 0]&ax0X ata~Y1 aybY2 bb
Y3bb5bZb~bat]:b)bb-]: 0b?ay\tbMbDbQ\t 0bdb\tbrbhbv\t 0cb\tcc
	c,dZeCecexfjDjHjlkk'k>kWkwll'lGmMmY\XdU]:c=c[d3\]cTcMcX\XcQ 0 X\cdc|d!cjd\tcu\]cy 0\td\]d P\td,\]d0 Xd7dF\c\;	\;\c	\$dj
\ddqedndu P]: 0e(\\*\$\$]:9eX_LABEL


eJ\6\;9eLLABEL		ei\t9ekLABEL\Xj:]:ff1fOggjf\*]f(fe}] 0\nfHfAfL\XfE 0 X\Lf^\fh
\$f
fxgfqf|\Xfu 0 P 0\G\*\]g!\ij 0g=gAg)g- 0g,Pg6\Gg: 0gFjgP\*\tgZ\n\]gjgyhRiiAigj\R\G\Gh\Gh\*h\th)\n\]h3h6hEhI 0h5P	\L\G 0hHV	\$
hXh\hli 0hZT(A1)W(She\Rhi 0hu]N\] 0i)i	i
i i#i2i7 0iW(Ii]\] 0i")P	\L\G 0i5V	\$
iGiKi[i^ 0iJW(S0)P	\L\R 0i]V\Gimiv	\$
j\Rj 0j \G]j.j%j2] 0jA 0jCT(A0)jR\*]j_jVjc] 0] j{]&\ikk]&\i]&k$ 0k1] ]&k5 0\XkM]\ik`kp]\i]kt 0k{\X]l 0] l]N\il0l@]N\i]NlD 0lQ] ]NlU 0l^H\\*\\0\$]]N]]&9l`LEGEND

mV9mXHOUSEKEEP
DEFINE PLOT STACKED_BAR
DECLARE X_REF, X_LENGTH, X_MIN, X_MAX, X_WIDTH
DECLARE Y_REF, Y_LENGTH, Y_MIN, Y_MAX, Y_LABEL
DECLARE BAR_Y, BAR_X, BAR_BOTTOM
DECLARE CNT, J_TEMP, K, KOUNT, OFFSET
DECLARE VECTOR Y_VALUE, Y_MX, COLOR

DECLARE STRING STNG
DECLARE STRING VECTOR L_LABEL, X_LABEL, HATCH
ENTRY 0 (X_LABEL : STRING,
         LABEL_1 : STRING,
         LABEL_2 : STRING,
         LABEL_3 : STRING)
BEGIN
    PLOT HOUSEKEEP 0
    PRINT "S(M 1(AH150L45S100)2(AH150L30S66)3(AH150L45S66))"
	    PRINT "L(A1)"
    PRINT "L""X""8142241818244281"
    PRINT "L""Y""8855225588552255"
    PRINT "L""Z""1122448888442211"
    HATCH(1) = "X"   COLOR(1) = 1   L_LABEL(1) = LABEL_1
    HATCH(2) = "Y"   COLOR(2) = 2   L_LABEL(2) = LABEL_2
    HATCH(3) = "Z"   COLOR(3) = 3   L_LABEL(3) = LABEL_3
"    X_REF = 100    Y_REF = 360    X_LENGTH = 600    Y_LENGTH = 350
#    PLOT LABEL 0 (X_REF, Y_REF, X_LENGTH, Y_LENGTH, X_LABEL, Y_LABEL)
LLABEL
        IF LENGTH(L_LABEL(CNT)) NE 0 THEN
            KOUNT = KOUNT + 1
END
ENTRY 1 (X : STRING, Y1, Y2, Y3)
BEGIN
    X_LABEL(SIZE(X_LABEL) + 1) = X
    Y_VALUE(SIZE(Y_VALUE) + 1) = Y1
    Y_VALUE(SIZE(Y_VALUE) + 1) = Y2
    Y_VALUE(SIZE(Y_VALUE) + 1) = Y3
END
ENTRY 2
BEGIN
 XLABEL
    BEGIN
        J_TEMP =      (CNT - 1) * 3
&        K = Y_VALUE(J_TEMP + 1) + Y_VALUE(J_TEMP + 2) + Y_VALUE(J_TEMP + 3)
        IF K GT Y_MAX THEN
            Y_MAX = K
    END
    X_WIDTH = X_LENGTH / ((2 * SIZE(X_LABEL)) + 1)
    PLOT X_LABEL 0 (X_REF, Y_REF, X_WIDTH, X_WIDTH, X_LABEL)
    PLOT LABEL 3 (Y_MIN, Y_MAX)
    PLOT LABEL 8 (Y_VALUE)
R XLABEL
    BEGIN
        Y_MX(SIZE(Y_MX) + 1) = Y_REF
        OFFSET =      (CNT - 1) * 3
        BAR_X = X_REF + X_WIDTH * (((CNT - 1) * 2) + 1)
        BAR_Y = Y_REF
        INCR J_TEMP FROM 1 TO KOUNT
        BEGIN
            PRINT "P", LY(BAR_Y - 1)
            IF Y_VALUE(OFFSET + J_TEMP) LT Y_REF THEN
	            BEGIN
                BAR_BOTTOM = BAR_Y
"                BAR_Y = BAR_Y - (Y_REF - Y_VALUE(OFFSET + J_TEMP))
                 PRINT "P", LXY(BAR_X, BAR_Y), "V", RX(X_WIDTH)
	(                PRINT "T(A1)W(S", LY(BAR_BOTTOM - 1), QUOTE(HATCH(J_TEMP)), ")"

-                PRINT "W(I", CVT(COLOR(J_TEMP)), ")P", LXY(BAR_X,BAR_Y), "V", RX(X_WIDTH)
#                PRINT "W(S0)P", LXY(BAR_X,BAR_BOTTOM), "V", LY(BAR_Y)
                PRINT RX(X_WIDTH), LY(BAR_BOTTOM - 1)
            END
        END
        Y_MX(SIZE(Y_MX) + 1) = BAR_Y
    END
	    PRINT "T(A0)"
    Y_MX(SIZE(Y_MX) + 1) = Y_REF
&    STNG = L_LABEL(KOUNT)   L_LABEL(KOUNT) = L_LABEL(1)   L_LABEL(1) = STNG
$    CNT = COLOR(KOUNT)     COLOR(KOUNT) = COLOR(1)       COLOR(1) = CNT
%    STNG = HATCH(KOUNT)     HATCH(KOUNT) = HATCH(1)       HATCH(1) = STNG
	*    PLOT LEGEND 3 (X_REF,Y_REF,X_LENGTH,Y_LENGTH,X_WIDTH,Y_MX,HATCH,COLOR,L_LABEL)
    PLOT HOUSEKEEP 2
END
END_PLOT