NLSY79 Appendix 1: Employment Status Recode Variables (1979-1998 and 2006)

National Longitudinal Survey of Youth - 1979 Cohort

NLSY79 Appendix 1: Employment Status Recode Variables (1979-1998 and 2006)

Employment Status Recode (ESR) is a standard measure of the respondent's main labor force activity during the survey week (Sunday through Saturday preceding the interview date). What follows is a PL/I adaptation of a Fortran program used by the Census Bureau to create ESR for 1979-1993, for 1994 through 1998, an SPSS adaptation of the decision rules provided by the Census Bureau to create MLR using the new CAPI-generated CPS data, and for 2006, a SAS adaptation of these rules.  Note that ESR was not created in 2000-2004 or 2008-present because the CPS section on activity in the week before the survey was not included in those rounds.

 

General Code: Variable Creation 1979-1983

 DCL 1 ESR_VARIABLES(5),
       5 ABSENT,
       5 ANYWK,
       5 DO4WKS,
       5 DOING,
       5 EMPLOY,
       5 EMPTYP,
       5 ESR,
       5 ESRC,
       5 HRSWK,
       5 INDTYP,
       5 LOOK,
       5 MILITARY,
       5 NEWJOB,
       5 OCCTYP,
       5 WEEKS,
       5 WEIGHT,
       5 WHYNOT,
       5 WHYOFF;

 

1979 VARIABLES

DOING(1)=R(434.);
          IF R(434.)<1 ! R(434.)>7 THEN DOING(1)=NA;
          ANYWK(1)=R(435.);
          IF R(435.)<0 ! R(435.)>1 THEN ANYWK(1)=NA;
          HRSWK(1)=R(436.);
          IF R(436.)<1 ! R(436.)>96 THEN HRSWK(1)=NA;
          IF R(444.)>0 THEN HRSWK(1)=R(444.);
          IF R(450.)>0 THEN HRSWK(1)=R(450.);
          HRANGE(1)=R(437.);
          IF R(437.)<1 ! R(437.)>3 THEN HRANGE(1)=NA;
          HRS35(1)=R(438.);
          IF R(438.)<0 ! R(438.)>1 THEN HRS35(1)=NA;
          REAS35(1)=R(439.);
          IF R(439.)<1 ! R(439.)>19 THEN REAS35(1)=NA;
          IF R(440.)>0 THEN REAS35(1)=R(440.);
          IF R(445.)=1 THEN HRANGE(1)=R(445.);
          IF R(446.)>0 THEN REAS35(1)=R(446.);
          OFFWORK(1)=R(441.);
          IF R(441.)<0 ! R(441.)>1 THEN OFFWORK(1)=NA;
          OTIME(1)=R(447.);
          IF R(447.)<0 ! R(447.)>1 THEN OTIME(1)=NA;
          ABSENT(1)=R(452.);
          IF R(452.)<0 ! R(452.)>1 THEN ABSENT(1)=NA;
          WHYOFF(1)=R(453.);
          IF R(453.)<1 R(453.)>9 THEN WHYOFF(1)=NA;
          SALARY(1)=R(459.);
          IF R(459.)<0 ! R(459.)>3 THEN SALARY(1)=NA;
          WORK35(1)=R(460.);
          IF R(460.)<0 ! R(460.)>1 THEN WORK35(1)=NA;
          LOOK(1)=R(511.);
          IF R(511.)<0 ! R(511.)>1 THEN LOOK(1)=NA;
          DO4WKS(1)=R(512.);
          WHYLK(1)=R(517.);
          IF R(517.)<1 ! R(517.)>11 THEN WHYLK(1)=NA;
          WEEKS(1)=R(457.);
          IF R(457.)<1 ! R(457.)>96 THEN WEEKS(1)=NA;
          IF R(519.)>0 THEN WEEKS(1)=R(519.);
          IF R(523.)>0 THEN WEEKS(1)=R(523.);
          WKTIME(1)=R(458.);
          IF R(458.)<1 ! R(458.)>2 THEN WKTIME(1)=NA;
          IF R(520.)>0 THEN WKTIME(1)=R(520.);
          IF R(524.)>0 THEN WKTIME(1)=R(524.);
          WHYNOT(1)=R(522.);
          IF R(522.)<1 ! R(522.)>5 THEN WHYNOT(1)=NA;
          IF R(521.)=0 THEN WHYNOT(1)=R(521.);
          IF R(525.)=0 THEN WHYNOT(1)=R(525.);
          IF R(526.)>0 THEN WHYNOT(1)=R(526.);
          INDTYP(1)=R(463.);
          IF R(463.)<0 ! R(463.)>998 THEN INDTYP(1)=NA;
          EMPTYP(1)=R(468.);
          IF R(468.)<0 ! R(468.)>4 THEN EMPTYP(1)=NA;
          OCCTYP(1)=R(464.);
          IF R(464.)<0 ! R(464.)>994 THEN OCCTYP(1)=NA;
          IF R(512.)>0 ! R(513.)>0 ! R(514.)>0 ! 
             R(515.)>0 ! R(516.)>0 THEN DO;
          IF R(512.)>1 ! R(513.)>1 ! R(514.)>1 ! 
             R(515.)>1 ! R(516.)>1 THEN DO;
          DO I=512. TO 516.;
             IF R(I)=1 THEN R(I)=-3;
             END;
             IF DO4WKS(1)<2 THEN DO4WKS(1)=10;
             END;
             IF (R(512.)=1 ! R(513.)=1 ! R(514.)=1 ! R(515.)=1 ! R(516.)=1) &
                DO4WKS(1)^=1 THEN DO4WKS(1)=1;
          END;
          ELSE DO4WKS(1)=NA;
          IF INDTYP(1)^=NA ! EMPTYP(1)^=NA ! OCCTYP(1)^=NA THEN EMPLOY(1)=1;
          ELSE EMPLOY(1)=0;
          IF R(433.)=1 THEN MILITARY(1)=1;
          ELSE MILITARY(1)=NA;
          WEIGHT(1)=R(2161.);

 

1980 VARIABLES

DOING(2)=R(2604.);
          IF R(2604.)<1 ! R(2604.)>7 THEN DOING(2)=NA;
          ANYWK(2)=R(2605.);
          IF R(2605.)<0 ! R(2605.)>1 THEN ANYWK(2)=NA;
          HRSWK(2)=R(2606.);
          IF R(2606.)<1 ! R(2606.)>96 THEN HRSWK(2)=NA;
          IF R(2614.)>0 THEN HRSWK(2)=R(2614.);
          IF R(2620.)>0 THEN HRSWK(2)=R(2640.);
          HRANGE(2)=R(2607.);
          IF R(2607.)<1 ! R(2607.)>3 THEN HRANGE(2)=NA;
          HRS35(2)=R(2608.);
          IF R(2608.)<0 ! R(2608.)>1 THEN HRS35(2)=NA;
          REAS35(2)=R(2609.);
          IF R(2609.)<1 ! R(2609.)>19 THEN REAS35(2)=NA;
          IF R(2610.)>0 THEN REAS(2)=R(2610.);
          IF R(2615.)=1 THEN HRANGE(2)=R(2615.);
          IF R(2616.)>0 THEN REAS35(2)=R(2616.);
          OFFWRK(2)=R(2611.);
          IF R(2611.)<0 ! R(2611.)>1 THEN OFFWRK(2)=NA;
          OTIME(2)=R(2617.);
          IF R(2617.)<0 ! R(2617.)>1 THEN OTIME(2)=NA;
          ABSENT(2)=R(2622.);
          IF R(2622.)<0 ! R(2622.)>1 THEN ABSENT(2)=NA;
          WHYOFF(2)=R(2623.);
          IF R(2623.)<1 ! R(2623.)>9 THEN WHYOFF(2)=NA;
          SALARY(2)=R(2629.);
          IF R(2629.)<0 ! R(2629.)>3 THEN SALARY(2)=NA;
          WORK35(2)=R(2630.);
          IF R(2630.)<0 ! R(2630.)>1 THEN WORK35(2)=NA;
          LOOK(2)=R(2681.);
          IF R(2681.)<0 ! R(2681.)>1 THEN LOOK(2)=NA;
          DO4WKS(2)=NA;
          IF R(2682.)=1 THEN DO4WKS(2)=1;
          ELSE IF R(2683.)>0 THEN DO4WKS(2)=2;
          ELSE IF R(2684.)>0 THEN DO4WKS(2)=3;
          ELSE IF R(2685.)>0 THEN DO4WKS(2)=4;
          ELSE IF R(2686.)>0 THEN DO4WKS(2)=5;
          ELSE IF R(2687.)>0 THEN DO4WKS(2)=6;
          ELSE IF R(2688.)>0 THEN DO4WKS(2)=7;
          ELSE IF R(2689.)>0 THEN DO4WKS(2)=8;
          ELSE IF R(2690.)>0 THEN DO4WKS(2)=9;
          WHYLK(2)=R(2691.);
          IF R(2691.)<1 ! R(2691.)>11 THEN WHYLK(2)=NA;
          WEEKS(2)=R(2627.);
          IF R(2627.)<1 ! R(2627.)>96 THEN WEEKS(2)=NA;
          IF R(2693.)>0 THEN WEEKS(2)=R(2693.);
          IF R(2697.)>0 THEN WEEKS(2)=R(2697.);
          WKTIME(2)=R(2628.);
          IF R(2628.)<1 ! R(2628.)>2 THEN WKTIME(2)=NA;
          IF R(2694.)>0 THEN WKTIME(2)=R(2694.);
          IF R(2698.)>0 THEN WKTIME(2)=R(2698.);
          WHYNOT(2)=R(2696.);
          IF R(2696.)<1 ! R(2696.)>5 THEN WHYNOT(2)=NA;
          IF R(2695.)=0 THEN WHYNOT(2)=R(2695.);
          IF R(2699.)=0 THEN WHYNOT(2)=R(2699.);
          IF R(2700.)>0 THEN WHYNOT(2)=R(2700.);
          INDTYP(2)=R(2633.);
          IF R(2633.)<0 ! R(2633.)>998 THEN INDTYP(2)=NA;
          EMPTYP(2)=R(2635.);
          IF R(2635.)<0 ! R(2635.)>4 THEN EMPTYP(2)=NA;
          OCCTYP(2)=R(2634.);
          IF R(2634.)<0 ! R(2634.)>994 THEN OCCTYP(2)=NA;
          IF R(2682.)>0 ! R(2683.)>0 ! R(2684.)>0 ! R(2685.)>0 ! R(2686.)>0 !
             R(2687.)>0 ! R(2688.)>0 ! R(2689.)>0 ! R(2690.)>0 THEN DO;
             IF R(2682.)>1 ! R(2683.)>1 ! R(2684.)>1 ! 
                R(2685.)>1 ! R(2686.)>1 !
                R(2687.)>1 ! R(2688.)>1 ! R(2689.)>1 ! R(2690.)>1 THEN DO;
                IF R(2682.)=1 THEN R(2682.)=-3;
                IF DO4WKS(2)<2 THEN DO4WKS(2)=10;
             END;
             IF R(2682.)=1 & DO4WKS(2)^=1 THEN DO4WKS(2)=1;
          END;
          ELSE DO4WKS(2)=NA;
          IF INDTYP(2)^=NA ! EMPTYP(2)^=NA ! OCCTYP(2)^=NA THEN EMPLOY(2)=1;
          ELSE EMPLOY(2)=0;
          IF R(2624.)<1 ! R(2624.)>2 THEN NEWJOB(2)=NA;
          ELSE NEWJOB(2)=R(2624.);
          WEIGHT(2)=R(4052.);
          IF R(2603.)=1 THEN MILITARY(2)=1;
          ELSE MILITARY(2)=NA;

 

1981 VARIABLES

 IF R(4434.)<1 THEN DOING(3)=NA;
          ELSE DOING(3)=R(4434.);
          IF R(4435.)<0 THEN ANYWK(3)=NA;
          ELSE ANYWK(3)=R(4435.);
          IF R(4436.)<1 THEN HRSWK(3)=NA;
          ELSE HRSWK(3)=R(4436.);
          IF R(4444.)>0 THEN HRSWK(3)=R(4444.);
          IF R(4450.)>0 THEN HRSWK(3)=R(4450.);
          IF R(4452.)<0 THEN ABSENT(3)=NA;
          ELSE ABSENT(3)=R(4452.);
          IF R(4453.)<1 THEN WHYOFF(3)=NA;
          ELSE WHYOFF(3)=R(4453.);
          IF R(4495.)<0 THEN LOOK(3)=NA;
          ELSE LOOK(3)=R(4495.);
          DO4WKS(3)=NA;
          IF R(4496.)=1 THEN DO4WKS(3)=1;
          IF R(4497.)>0 ! R(4498.)>0 ! R(4499.)>0 ! R(4500.)>0 ! R(4501.)>0 !
             R(4502.)>0 ! R(4503.)>0 ! R(4504.)>0 THEN DO4WKS(3)=2;
          IF R(4457.)<1 THEN WEEKS(3)=NA;
          ELSE WEEKS(3)=R(4457.);
          IF R(4507.)>0 THEN WEEKS(3)=R(4507.);
          IF R(4511.)>0 THEN WEEKS(3)=R(4511.);
          IF R(4510.)<1 THEN WHYNOT(3)=NA;
          ELSE WHYNOT(3)=R(4510.);
          IF R(4509.)=0 ! R(4513.)=0 THEN WHYNOT(3)=0;
          IF R(4514.)>0 THEN WHYNOT(3)=R(4514.);
          IF R(4463.)<0 ! R(4463.)>998 THEN INDTYP(3)=NA;
          ELSE INDTYP(3)=R(4463.);
          IF R(4464.)<0 ! R(4464.)>994 THEN OCCTYP(3)=NA;
          ELSE OCCTYP(3)=R(4464.);
          IF R(4466.)<0 THEN EMPTYP(3)=NA;
          ELSE EMPTY(3)=R(4466.);
          IF R(4454.)<1 ! R(4454.)>2 THEN NEWJOB(3)=NA;
          ELSE NEWJOB(3)=R(4454.);
          IF INDTYP(3)^=NA ! OCCTYP(3)^=NA ! EMPTYP(3)^=NA THEN EMPLOY(3)=1;
          ELSE EMPLOY(3)=0;
          WEIGHT(3)=R(6146.);
          IF R(4433.)=1 THEN MILITARY(3)=1;
          ELSE MILITARY(3)=NA;


1982 VARIABLES

IF R(6935.)<1 THEN DOING(4)=NA;
          ELSE DOING(4)=R(6935.);
          IF R(6936.)<0 THEN ANYWK(4)=NA;
          ELSE ANYWK(4)=R(6936.);
          IF R(6937.)<1 THEN HRSWK(4)=NA;
          ELSE HRSWK(4)=R(6937.);
          IF R(6945.)>0 THEN HRSWK(4)=R(6945.);
          IF R(6951.)>0 THEN HRSWK(4)=R(6951.);
          IF R(6953.)<0 THEN ABSENT(4)=NA;
          ELSE ABSENT(4)=R(6953.);
          IF R(6954.)<1 THEN WHYOFF(4)=NA;
          ELSE WHYOFF(4)=R(6954.);
          IF R(6963.)<0 THEN LOOK(4)=NA;
          ELSE LOOK(4)=R(6963.);
          DO4WKS(4)=NA;
          IF R(6964.)=1 THEN DO4WKS(4)=1;
          IF R(6965.)>0 ! R(6966.)>0 ! R(6967.)>0 ! R(6968.)>0 ! R(6969.)>0 !
             R(6970.)>0 ! R(6971.)>0 ! R(6972.)>0 THEN DO4WKS(4)=2;
          IF R(6958.)<1 THEN WEEKS(4)=NA;
          ELSE WEEKS(4)=R(6958.);
          IF R(6975.)>0 THEN WEEKS(4)=R(6975.);
          IF R(6979.)>0 THEN WEEKS(4)=R(6979.);
          IF R(6978.)<1 THEN WHYNOT(4)=NA;
          ELSE WHYNOT(4)=R(6978.);
          IF R(6977.)=0 ! R(6981.)=0 THEN WHYNOT(4)=0;
          IF R(6982.)>0 THEN WHYNOT(4)=R(6982.);
          IF R(7020.)<0 ! R(7020.)>998 THEN INDTYP(4)=NA;
          ELSE INDTYP(4)=R(7020.);
          IF R(7021.)<0 ! R(7021.)>994 THEN OCCTYP(4)=NA;
          ELSE OCCTYP(4)=R(7021.);
          IF R(7023.)<0 THEN EMPTYP(4)=NA;
          ELSE EMPTYP(4)=R(7023.);
          IF R(6955.)<1 ! R(6955.)>2 THEN NEWJOB(4)=NA;
          ELSE NEWJOB(4)=R(6955.);
          IF (INDTYP(4)^=NA ! OCCTYP(4)^=NA ! EMPTYP(4)^=NA) & R(6983.)^=1 &
             R(7009.)^=1 THEN EMPLOY(4)=1;
          ELSE EMPLOY(4)=0;
          WEIGHT(4)=R(8967.);
          IF R(6934.)=1 THEN MILITARY(4)=1;
          ELSE MILITARY(4)=NA;

 

1983 VARIABLES

 IF R(9365.)<1 THEN DOING(5)=NA;
          ELSE DOING(5)=R(9365.);
          IF R(9366.)<0 THEN ANYWK(5)=NA;
          ELSE ANYWK(5)=R(9366.);
          IF R(9367.)<1 THEN HRSWK(5)=NA;
          ELSE HRSWK(5)=R(9367.);
          IF R(9375.)>0 THEN HRSWK(5)=R(9375.);
          IF R(9381.)>0 THEN HRSWK(5)=R(9381.);
          IF R(9383.)<0 THEN ABSENT(5)=NA;
          ELSE ABSENT(5)=R(9383.);
          IF R(9384.)<1 THEN WHYOFF(5)=NA;
          ELSE WHYOFF(5)=R(9384.);
          IF R(9393.)<0 THEN LOOK(5)=NA;
          ELSE LOOK(5)=R(9393.);
          DO4WKS(5)=NA;
          IF R(9394.)=1 THEN DO4WKS(5)=1;
          IF R(9395.)>0 ! R(9396.)>0 ! R(9397.)>0 ! R(9398.)>0 ! R(9399.)>0 !
             R(9400.)>0 ! R(9401.)>0 ! R(9402.)>0 THEN DO4WKS(5)=2;
          IF R(9388.)<1 THEN WEEKS(5)=NA;
          ELSE WEEKS(5)=R(9388.);
          IF R(9405.)>0 THEN WEEKS(5)=R(9405.);
          IF R(9408.)>0 THEN WEEKS(5)=R(9408.);
          IF R(9407.)=0 ! R(9410.)=0 THEN WHYNOT(5)=0;
          IF R(9411.)>0 THEN WHYNOT(5)=R(9411.);
          IF R(9449.)<0 ! R(9449.)>998 THEN INDTYP(5)=NA;
          ELSE INDTYP(5)=R(9449.);
          IF R(9450.)<0 ! R(9450.)>994 THEN OCCTYP(5)=NA;
          ELSE OCCTYP(5)=R(9450.);
          IF R(9454.)<0 THEN EMPTYP(5)=NA;
          ELSE EMPTYP(5)=R(9454.);
          IF R(9385.)<1 ! R(9385.)>2 THEN NEWJOB(5)=NA;
          ELSE NEWJOB(5)=R(9385.);
          IF (INDTYP(5)^=NA ! OCCTYP(5)^=NA ! EMPTYP(5)^=NA) & R(9412.)^=1 &
             R(9439.)^=1 THEN EMPLOY(5)=1;
          ELSE EMPLOY(5)=0;
          WEIGHT(5)=R(11444.);
          IF R(9364.)=1 THEN MILITARY(5)=1;
          ELSE MILITARY(5)=NA;
          DO I=1 TO 5;
             IF MILITARY(I)=1 THEN DO;
                ESR(I)=8;
                GO TO FIN;
             END;
             IF I=1 & R(1.)=6435 THEN DO;
                ESR(1)=-3;
                GO TO FIN;
             END;
             IF WEIGHT(I)=0 THEN DO;
                ESR(I)=-5;
                GO TO FIN;
             END;
             ESR(I)=7;
             IF DOING(I)^=1 THEN GO TO P6;
             IF HRSWK(I)=NA THEN GO TO P4;
             IF HRSWK(I)>=15 ! EMPTYP(I)^=4 THEN ESR(I)=1;
             GO TO P20000;
             P4: IF EMPLOY(I)=1 THEN ESR(I)=1;
             GO TO P20000;
             P6: ESR(I)=1;
             IF ANYWK(I)^=1 THEN GO TO P11;
             IF HRSWK(I)=NA THEN GO TO P9;
             IF HRSWK(I)<15 & EMPTYP(I)=4 THEN GO TO P61;
             GO TO P62;
             P9: IF EMPLOY(I)=0 THEN GO TO P61;
             GO TO P62;
             P11: IF HRSWK(I)=NA THEN GO TO P15;
             IF EMPLOY(I)=0 THEN GO TO P61;
             IF HRSWK(I)<15 & EMPTYP(I)=4 THEN GO TO P61;
             GO TO P62;
             P15: ESR(I)=7;
             IF DOING(I)=2 THEN GO TO ESR237;
             IF DOING(I)=3 THEN GO TO P21;
             GO TO P37;
             P21: IF ABSENT(I)^=1 THEN GO TO P27;
             GO TO ESR237;
             P27: IF WHYOFF(I)=NA THEN GO TO P32;
             IF WHYOFF(I)=6 ! WHYOFF(I)=7 THEN GO TO P29;
             IF EMPLOY(I)^=0 & EMPTYP(I)^=4 THEN ESR(I)=2;
             GO TO P20000;
             P29: IF WHYNOT(I)<3 THEN ESR(I)=3;
             GO TO P20000;
             P32: IF DO4WKS(I)=1 THEN GO TO P20000;
             IF WHYNOT(I)>2 THEN GO TO P20000;
             IF WEEKS(I)=NA THEN GO TO P33;
             ESR(I)=3;
             GO TO P20000;
             P33: IF DO4WKS(I)>1 ! WHYNOT(I)^=NA THEN ESR(I)=3;
             GO TO P20000;
             P37: ESR(I)=2;
             IF ABSENT(I)^=1 THEN GO TO P43;
             IF WHYOFF(I)=NA THEN GO TO P41;
             IF WHYOFF(I)=6 ! WHYOFF(I)=7 THEN GO TO P39;
             IF EMPTYP(I)=4 THEN GO TO P61;
             GO TO P62;
             P39: IF WHYNOT(I)>2 THEN GO TO P61;
             ESR(I)=3;
             GO TO P62;
             P41: IF EMPLOY(I)=0 ! EMPTYP(I)=4 THEN GO TO P61;
             GO TO P62;
             P43: IF WHYOFF(I)=NA THEN GO TO P48;
             IF WHYOFF(I)=6 ! WHYOFF(I)=7 THEN GO TO P45;
             IF EMPLOY(I)=0 ! EMPTYP(I)=4 THEN GO TO P61;
             GO TO P62;
             P45: IF WEEKS(I)=NA & WHYNOT(I)=NA THEN GO TO P61;
             IF WHYNOT(I)>2 THEN GO TO P61;
             ESR(I)=3;
             GO TO P62;
             P48: ESR(I)=3;
             IF LOOK(I)^=1 THEN GO TO P53;
             IF DO4WKS(I)=1 THEN GO TO P61;
             IF WHYNOT(I)>2 THEN GO TO P61;
             IF DO4WKS(I)^=NA  ! WEEKS(I)^=NA THEN GO TO P62;
             IF WHYNOT(I)=NA THEN GO TO P61;
             GO TO P62;
             P53: IF DO4WKS(I)=1 THEN GO TO P61;
             IF WHYNOT(I)>2 THEN GO TO P61;
             IF DO4WKS(I)=NA THEN GO TO P56;
             IF WEEKS(I)^=NA ! WHYNOT(I)^=NA THEN GO TO P62;
             GO TO P61;
             P56: IF WEEKS(I)=NA ! WHYNOT(I)=NA THEN GO TO P61;
             GO TO P62;
             P61: IF DOING(I)<4 ! DOING(I)>6 THEN GO TO P610;
             ESR(I)=DOING(I);
             GO TO P20000;
             P610: ESR(I)=7;
             GO TO P20000;
             P62: IF DOING(I)=6 THEN DOING(I)=7;
             P20000: GO TO FIN;
             ESR237: IF WHYOFF(I)=NA THEN GO TO P5019;
             IF WHYOFF(I)=6 ! WHYOFF(I)=7 THEN GO TO P5017;
             IF EMPTYP(I)^=-4 THEN ESR(I)=2;
             GO TO FIN;
             P5017: IF WHYNOT(I)>2 THEN GO TO FIN;
             ESR(I)=3;
             GO TO FIN;
             P5019: IF EMPLOY(I)=1 & EMPTYP(I)^=4 THEN ESR(I)=2;
             FIN:;

 

COLLAPSED EMPLOYMENT STATUS RECODE 1979-1983

IF ESR(I)=-5 THEN ESRC(I)=-5;
  ELSE IF ESR(I)=1 | ESR(I)=2 THEN ESRC(I)=1;
  ELSE IF ESR(I)=3 THEN ESRC(I)=2;
  ELSE IF ESR(I)>=4 & ESR(I)<=7 THEN ESRC(I)=3;
  ELSE IF ESR(I)=8 THEN ESRC(I)=4;
  ELSE ESRC(I)=ESR(I);
 END;
 
          R(2149.)=ESR(1);
          R(4063.)=ESR(2);
          R(6188.)=ESR(3);
          R(8985.)=ESR(4);
          R(11447.)=ESR(5);
          R(2149.01)=ESRC(1);
          R(4063.01)=ESRC(2);
          R(6188.01)=ESRC(3);
          R(8985.01)=ESRC(4);
          R(11447.01)=ESRC(5);

 

General Code: Variable Creation 1984-1993

            5 ABSENT,
         5 ANYWK,
         5 DO4WKS,
         5 DOING,
         5 EMPLOY,
         5 EMPTYP,
         5 ESR,
         5 ESRC,
         5 HRSWK,
         5 INDTYP,
         5 LOOK,
         5 MILITARY,
         5 NEWJOB,
         5 OCCTYP,
         5 WEEKS,
         5 WEIGHT,
         5 WHYNOT,
         5 WHYOFF;

 

1984 VARIABLES

ESR84=-4;
          IF R(12468.)<1 THEN DOING(6)=NA;
          ELSE DOING(6)=R(12468.);
          IF R(12469.)<0 THEN ANYWK(6)=NA;
          ELSE ANYWK(6)=R(12469.);
          IF R(12470.)<1 THEN HRSWK(6)=NA;
          ELSE HRSWK(6)=R(12470.);
          IF R(12478.)>0 THEN HRSWK(6)=R(12478.);
          IF R(12484.)>0 THEN HRSWK(6)=R(12484.);
          IF R(12486.)<0 THEN ABSENT(6)=NA;
          ELSE ABSENT(6)=R(12486.);
          IF R(12487.)<1 THEN WHYOFF(6)=NA;
          ELSE WHYOFF(6)=R(12487.);
          IF R(12496.)<0 THEN LOOK(6)=NA;
          ELSE LOOK(6)=R(12496.);
          DO4WKS(6)=NA;
          IF R(12497.)=1 THEN DO4WKS(6)=1;
          IF R(12498.)>0 ! R(12499.)>0 ! R(12500.)>0 ! R(12501.)>0 !
              R(12502.)>0 ! R(12503.)>0 ! R(12504.)>0 ! R(12505.)>0
             THEN DO4WKS(6)=2;
          IF R(12491.)<1 THEN WEEKS(6)=NA;
          ELSE WEEKS(6)=R(12491.);
          IF R(12508.)>0 THEN WEEKS(6)=R(12508.);
          IF R(12512.)>0 THEN WEEKS(6)=R(12512.);
          IF R(12510.)=0 ! R(12514.)=0 THEN WHYNOT(6)=0;
          IF R(12515.)>0 THEN WHYNOT(6)=R(12515.);
          IF R(12553.)<0 ! R(12553.)>998 THEN INDTYP(6)=NA;
          ELSE INDTYP(6)=R(12553.);
          IF R(12554.)<0 ! R(12554.)>994 THEN OCCTYP(6)=NA;
          ELSE OCCTYP(6)=R(12554.);
          IF R(12558.)<0 THEN EMPTYP(6)=NA;
          ELSE EMPTYP(6)=R(12558.);
          IF R(12488.)<1 ! R(12488.)>2 THEN NEWJOB(6)=NA;
          ELSE NEWJOB(6)=R(12488.);
          IF (INDTYP(6)^=NA ! OCCTYP(6)^=NA ! EMPTYP(6)^=NA) & R(12516.)^=1 &
             R(12543.)^=1 THEN EMPLOY(6)=1;
          ELSE EMPLOY(6)=0;
          WEIGHT(6)=R(15196.);
          IF R(12467.)=1 THEN MILITARY(6)=1;
          ELSE MILITARY(6)=NA;

 

1985 VARIABLES

          IF R(16420.)<1 THEN DOING(7)=NA;
          ELSE DOING(7)=R(16420.);
          IF R(16421.)<0 THEN ANYWK(7)=NA;
          ELSE ANYWK(7)=R(16421.);
          IF R(16422.)<1 THEN HRSWK(7)=NA;
          ELSE HRSWK(7)=R(16422.);
          IF R(16430.)>0 THEN HRSWK(7)=R(16430.);
          IF R(16436.)>0 THEN HRSWK(7)=R(16436.);
          IF R(16438.)<0 THEN ABSENT(7)=NA;
          ELSE ABSENT(7)=R(16438.);
          IF R(16439.)<1 THEN WHYOFF(7)=NA;
          ELSE WHYOFF(7)=R(16439.);
          IF R(16448.)<0 THEN LOOK(7)=NA;
          ELSE LOOK(7)=R(16448.);
          DO4WKS(7)=NA;
          IF R(16449.)=1 THEN DO4WKS(7)=1;
          IF R(16450.)>0 ! R(16451.)>0 ! R(16452.)>0 ! R(16453.)>0 !
             R(16454.)>0 ! R(16455.)>0 ! R(16456.)>0 ! R(16457.)>0
             THEN DO4WKS(7)=2;
          IF R(16443.)<1 THEN WEEKS(7)=NA;
          ELSE WEEKS(7)=R(16443.);
          IF R(16460.)>0 THEN WEEKS(7)=R(16460.);
          IF R(16464.)>0 THEN WEEKS(7)=R(16464.);
          IF R(16462.)=0 ! R(16466.)=0 THEN WHYNOT(7)=0;
          IF R(16467.)>0 THEN WHYNOT(7)=R(16467.);
          IF R(16501.)<0 ! R(16501.)>998 THEN INDTYP(7)=NA;
          ELSE INDTYP(7)=R(16501.);
          IF R(16502.)<0 ! R(16502.)>994 THEN OCCTYP(7)=NA;
          ELSE OCCTYP(7)=R(16502.);
          IF R(16506.)<0 THEN EMPTYP(7)=NA;
          ELSE EMPTYP(7)=R(16506.);
          IF R(16440.)<1 ! R(16440.)>2 THEN NEWJOB(7)=NA;
          ELSE NEWJOB(7)=R(16440.);
          IF (INDTYP(7)^=NA ! OCCTYP(7)^=NA ! EMPTYP(7)^=NA) & R(16468.)^=1 &
             R(16493.)^=1 THEN EMPLOY(7)=1;
          ELSE EMPLOY(7)=0;
          WEIGHT(7)=R(18902.);
          IF R(16419.)=1 THEN MILITARY(7)=1;
          ELSE MILITARY(7)=NA;

 

1986 VARIABLES

          IF R(19146.)<1 THEN DOING(8)=NA;
          ELSE DOING(8)=R(19146.);
          IF R(19147.)<0 THEN ANYWK(8)=NA;
          ELSE ANYWK(8)=R(19147.);
          IF R(19148.)<1 THEN HRSWK(8)=NA;
          ELSE HRSWK(8)=R(19148.);
          IF R(19156.)>0 THEN HRSWK(8)=R(19156.);
          IF R(19162.)>0 THEN HRSWK(8)=R(19162.);
          IF R(19164.)<0 THEN ABSENT(8)=NA;
          ELSE ABSENT(8)=R(19164.);
          IF R(19165.)<1 THEN WHYOFF(8)=NA;
          ELSE WHYOFF(8)=R(19165.);
          IF R(19174.)<0 THEN LOOK(8)=NA;
          ELSE LOOK(8)=R(19174.);
          DO4WKS(8)=NA;
          IF R(19175.)=1 THEN DO4WKS(8)=1;
          IF R(19176.)>0 ! R(19177.)>0 ! R(19178.)>0 ! R(19179.)>0 !
             R(19180.)>0 ! R(19181.)>0 ! R(19182.)>0 ! R(19183.)>0
             THEN DO4WKS(8)=2;
          IF R(19169.)<1 THEN WEEKS(8)=NA;
          ELSE WEEKS(8)=R(19169.);
          IF R(19186.)>0 THEN WEEKS(8)=R(19186.);
          IF R(19190.)>0 THEN WEEKS(8)=R(19190.);
          IF R(19188.)=0 ! R(19192.)=0 THEN WHYNOT(8)=0;
          IF R(19193.)>0 THEN WHYNOT(8)=R(19193.);
          IF R(19227.)<0 ! R(19227.)>998 THEN INDTYP(8)=NA;
          ELSE INDTYP(8)=R(19227.);
          IF R(19228.)<0 ! R(19228.)>994 THEN OCCTYP(8)=NA;
          ELSE OCCTYP(8)=R(19228.);
          IF R(19232.)<0 THEN EMPTYP(8)=NA;
          ELSE EMPTYP(8)=R(19232.);
          IF R(19166.)<1 ! R(19166.)>2 THEN NEWJOB(8)=NA;
          ELSE NEWJOB(8)=R(19166.);
          IF (INDTYP(8)^=NA ! OCCTYP(8)^=NA ! EMPTYP(8)^=NA) & R(19194.)^=1 &
             R(19219.)^=1 THEN EMPLOY(8)=1;
          ELSE EMPLOY(8)=0;
          WEIGHT(8)=R(22573.);
          MILCUR=R(19115.);
          IF R(19141.)>=0 THEN MILCUR=R(19141.);
          IF MILCUR=1 THEN MILITARY(8)=1;
          ELSE MILTARY(8)=NA;

 

1987 VARIABLES

          IF R(23107.)<1 THEN DOING(9)=NA;
          ELSE DOING(9)=R(23107.);
          IF R(23108.)<0 THEN ANYWK(9)=NA;
          ELSE ANYWK(9)=R(23108.);
          IF R(23109.)<1 THEN HRSWK(9)=NA;
          ELSE HRSWK(9)=R(23109.);
          IF R(23117.)>0 THEN HRSWK(9)=R(23117.);
          IF R(23123.)>0 THEN HRSWK(9)=R(23123.);
          IF R(23125.)<0 THEN ABSENT(9)=NA;
          ELSE ABSENT(9)=R(23125.);
          IF R(23126.)<1 THEN WHYOFF(9)=NA;
          ELSE WHYOFF(9)=R(23126.);
          IF R(23135.)<0 THEN LOOK(9)=NA;
          ELSE LOOK(9)=R(23135.);
          DO4WKS(9)=NA;
          IF R(23136.)=1 THEN DO4WKS(9)=1;
          IF R(23137.)>0 ! R(23138.)>0 ! R(23139.)>0 ! R(23140.)>0 !
             R(23141.)>0 ! R(23142.)>0 ! R(23143.)>0 ! R(23144.)>0
             THEN DO4WKS(9)=2;
          IF R(23130.)<1 THEN WEEKS(9)=NA;
          ELSE WEEKS(9)=R(23130.);
          IF R(23147.)>0 THEN WEEKS(9)=R(23147.);
          IF R(23151.)>0 THEN WEEKS(9)=R(23151.);
          IF R(23149.)=0 ! R(23153.)=0 THEN WHYNOT(9)=0;
          ELSE IF R(23154.)>0 THEN WHYNOT(9) =R(23154.);
          ELSE IF R(23150.)>0 THEN WHYNOT(9)=R(23150.);
          ELSE WHYNOT(9)=NA;
          IF R(23175.)<0 ! R(23175.)>998 THEN INDTYP(9)=NA;
          ELSE INDTYP(9)=R(23175.);
          IF R(23176.)<0 ! R(23176.)>994 THEN OCCTYP(9)=NA;
          ELSE OCCTYP(9)=R(23176.);
          IF R(23180.)<0 THEN EMPTYP(9)=NA;
          ELSE EMPTYP(9)=R(23180.);
          IF R(23127.)<1 ! R(23127.)>2 THEN NEWJOB(9)=NA;
          ELSE NEWJOB(9)=R(23127.);
          IF (INDTYP(9)^=NA ! OCCTYP(9)^=NA ! EMPTYP(9)^=NA) & R(23155.)^=1 &
             R(23174.)^=1 THEN EMPLOY(9)=1;
          ELSE EMPLOY(9)=0;
                        WEIGHT(9)=R(24445.);
          MILCUR=R(23075.);
          IF R(23102.)>=0 THEN MILCUR=R(23102.);
          IF MILCUR=1 THEN MILITARY(9)=1;
          ELSE MILITARY(9)=NA;

 

1988 VARIABLES

          IF R(25186.)<1 THEN DOING(10)=NA;
          ELSE DOING(10)=R(25186.);
          IF R(25187.)<0 THEN ANYWK(10)=NA;
          ELSE ANYWK(10)=R(25187.);
          IF R(25188.)<1 THEN HRSWK(10)=NA;
          ELSE HRSWK(10)=R(25188.);
          IF R(25196.)>0 THEN HRSWK(10)=R(25196.);
          IF R(25202.)>0 THEN HRSWK(10)=R(25202.);
          IF R(25204.)<0 THEN ABSENT(10)=NA;
          ELSE ABSENT(10)=R(25204.);
          IF R(25205.)<1 THEN WHYOFF(10)=NA;
          ELSE WHYOFF(10)=R(25205.);
          IF R(25214.)<0 THEN LOOK(10)=NA;
          ELSE LOOK(10)=R(25214.);
          DO4WKS(10)=NA;
          IF R(25215.)=1 THEN DO4WKS(10)=1;
          IF R(25216.)>0 ! R(25217.)>0 ! R(25218.)>0 ! R(25219.)>0 !
             R(25220.)>0 ! R(25221.)>0 ! R(25222.)A>0 ! R(25223.)>0
             THEN DO4WKS(10)=2;
          IF R(25209.)<1 THEN WEEKS(10)=NA;
          ELSE WEEKS(10)=R(25209.);
          IF R(25226.)>0 THEN WEEKS(10)=R(25226.);
          IF R(25230.)>0 THEN WEEKS(10)=R(25230.);
          IF R(25228.)=0 ! R(25232.)=0 THEN WHYNOT(10)=0;
          ELSE IF R(25233.)>0 THEN WHYNOT(10)=R(25233.);
          ELSE IF R(25229.)>0 THEN WHYNOT(10)=R(25229.);
          ELSE WHYNOT(10)=NA;
          IF R(25253.)<0 ! R(25253.)>998 THEN INDTYP(10)=NA;
          ELSE INDTYP(10)=R(25253.);
          IF R(25254.)<0 ! R(25254.)>994 THEN OCCTYP(10)=NA;
          ELSE OCCTYP(10)=R(25254.);
          IF R(25258.)<0 THEN EMPTYP(10)=NA;
          ELSE EMPTYP(10)=R(25258.);
          IF R(25206.)<1 ! R(25206.)>2 THEN NEWJOB(10)=NA;
          ELSE NEWJOB(10)=R(25206.);
          IF (INDTYP(10)^=NA ! OCCTYP(10)^=NA ! EMPTYP(10)^=NA) & R(25234.)^=1
             & R(25252.)^=1 THEN EMPLOY(10)=1;
          ELSE EMPLOY(10)=0;
          WEIGHT(10)=R(28700.);
          MILCUR=R(25154.);
          IF R(25181.)>=0 THEN MILCUR=R(25181.);
          IF MILCUR=1 THEN MILITARY(10)=1;
          ELSE MILITARY(10)=NA;

 

1989 VARIABLES

          IF R(29175.)<1 THEN DOING(11)=NA;
          ELSE DOING(11)=R(29175.);
          IF R(29176.)<0 THEN ANYWK(11)=NA;
          ELSE ANYWK(11)=R(29176.);
          IF R(29177.)<1 THEN HRSWK(11)=NA;
          ELSE HRSWK(11)=R(29177.);
          IF R(29185.)>0 THEN HRSWK(11)=R(29185.);
          IF R(29191.)>0 THEN HRSWK(11)=R(29191.);
          IF R(29193.)<0 THEN ABSENT(11)=NA;
          ELSE ABSENT(11)=R(29193.);
          IF R(29194.)<1 THEN WHYOFF(11)=NA;
          ELSE WHYOFF(11)=R(29194.);
          IF R(29203.)<0 THEN LOOK(11)=NA;
          ELSE LOOK(11)=R(29203.);
          DO4WKS(11)=NA;
          IF R(29204.)=1 THEN DO4WKS(11)=1;
          IF R(29205.)>0 ! R(29206.)>0 ! R(29207.)>0 ! R(29208.)>0 ! R(29209.)>0 !
             R(29210.)>0 ! R(29211.)>0 ! R(29212.)>0 THEN DO4WKS(11)=2;
          IF R(29198.)<1 THEN WEEKS(11)=NA;
          ELSE WEEKS(11)=R(29198.);
          IF R(29215.)>0 THEN WEEKS(11)=R(29215.);
          IF R(29219.)>0 THEN WEEKS(11)=R(29219.);
          IF R(29217.)=0 ! R(29221.)=0 THEN WHYNOT(11)=0;
          ELSE IF R(29222.)>0 THEN WHYNOT(11) =R(29222.);
          ELSE IF R(29218.)>0 THEN WHYNOT(11)=R(29218.);
          ELSE WHYNOT(11)=NA;
          IF R(29243.)<0 ! R(29243.)>998 THEN INDTYP(11)=NA;
          ELSE INDTYP(11)=R(29243.);
          IF R(29244.)<0 ! R(29244.)>994 THEN OCCTYP(11)=NA;
          ELSE OCCTYP(11)=R(29244.);
          IF R(29248.)<0 THEN EMPTYP(11)=NA;
          ELSE EMPTYP(11)=R(29248.);
          IF R(29195.)<1 ! R(29195.)>2 THEN NEWJOB(11)=NA;
          ELSE NEWJOB(11)=R(29195.);
          IF (INDTYP(11)^=NA ! OCCTYP(11)^=NA ! EMPTYP(11)^=NA) & R(29223.)^=1 &
             R(29242.)^=1 THEN EMPLOY(11)=1;
          ELSE EMPLOY(11)=0;
          WEIGHT(11)=R(30738.);
          MILCUR=R(29143.);
          IF R(29170.)>=0 THEN MILCUR=R(29170.);
          IF MILCUR=1 THEN MILITARY(11)=1;
          ELSE MILITARY(11)=NA;

 

1990 VARIABLES

          WEIGHT(12)=R(34002.);
          IF R(31197.)<1 THEN DOING(12)=NA;
          ELSE DOING(12)=R(31197.);
          IF R(31198.)<0 THEN ANYWK(12)=NA;
          ELSE ANYWK(12)=R(31198.);
          IF R(31199.)<1 THEN HRSWK(12)=NA;
          ELSE HRSWK(12)=R(31199.);
          IF R(31207.)>0 THEN HRSWK(12)=R(31207.);
          IF R(31213.)>0 THEN HRSWK(12)=R(31213.);
          IF R(31220.)<0 THEN ABSENT(12)=NA;
          ELSE ABSENT(12)=R(31220.);
          IF R(31221.)<1 THEN WHYOFF(12)=NA;
          ELSE WHYOFF(12)=R(31221.);
          IF R(31230.)<0 THEN LOOK(12)=NA;
          ELSE LOOK(12)=R(31230.);
          DO4WKS(12)=NA;
          IF R(31231.)=1 THEN DO4WKS(12)=1;
          IF R(31232.)>0 ! R(31233.)>0 ! R(31234.)>0 ! R(31235.)>0 ! R(31236.)>0 !
             R(31237.)>0 ! R(31238.)>0 ! R(31239.)>0 THEN DO4WKS(12)=2;
          IF R(31225.)<1 THEN WEEKS(12)=NA;
          ELSE WEEKS(12)=R(31225.);
          IF R(31242.)>0 THEN WEEKS(12)=R(31242.);
          IF R(31246.)>0 THEN WEEKS(12)=R(31246.);
          IF R(31244.)=0 ! R(31248.)=0 THEN WHYNOT(12)=0;
          ELSE IF R(31249.)>0 THEN WHYNOT(12) =R(31249.);
          ELSE IF R(31245.)>0 THEN WHYNOT(12)=R(31245.);
          ELSE WHYNOT(12)=NA;
          IF R(31270.)<0 ! R(31270.)>998 THEN INDTYP(12)=NA;
          ELSE INDTYP(12)=R(31270.);
          IF R(31271.)<0 ! R(31271.)>994 THEN OCCTYP(12)=NA;
          ELSE OCCTYP(12)=R(31271.);
          IF R(31275.)<0 THEN EMPTYP(12)=NA;
          ELSE EMPTYP(12)=R(31275.);
          IF R(31222.)<1 ! R(31222.)>2 THEN NEWJOB(12)=NA;
          ELSE NEWJOB(12)=R(31222.);
          IF (INDTYP(12)^=NA ! OCCTYP(12)^=NA ! EMPTYP(12)^=NA) & R(31250.)^=1 &
             R(31271.)^=1 THEN EMPLOY(12)=1;
          ELSE EMPLOY(12)=0;
          MILCUR=R(31165.);
          IF R(31192.)>=0 THEN MILCUR=R(31192.);
          IF MILCUR=1 THEN MILITARY(12)=1;
          ELSE MILITARY(12)=NA;

 

1991 VARIABLES

          WEIGHT(13)=R(36558.);
          IF R(35154.)<1 THEN DOING(13)=NA;
          ELSE DOING(13)=R(35154.);
          IF R(35155.)<0 THEN ANYWK(13)=NA;
          ELSE ANYWK(13)=R(35155.);
          IF R(35156.)<1 THEN HRSWK(13)=NA;
          ELSE HRSWK(13)=R(35156.);
          IF R(35164.)>0 THEN HRSWK(13)=R(35164.);
          IF R(35170.)>0 THEN HRSWK(13)=R(35170.);
          IF R(35177.)<0 THEN ABSENT(13)=NA;
          ELSE ABSENT(13)=R(35177.);
          IF R(35178.)<1 THEN WHYOFF(13)=NA;
          ELSE WHYOFF(13)=R(35178.);
          IF R(35187.)<0 THEN LOOK(13)=NA;
          ELSE LOOK(13)=R(35187.);
          DO4WKS(13)=NA;
          IF R(35188.)=1 THEN DO4WKS(13)=1;
          IF R(35189.)>0 ! R(35190.)>0 ! R(35191.)>0 ! R(35192.)>0 ! R(35193.)>0 !
             R(35194.)>0 ! R(35195.)>0 ! R(35196.)>0 THEN DO4WKS(13)=2;
          IF R(35182.)<1 THEN WEEKS(13)=NA;
          ELSE WEEKS(13)=R(35182.);
          IF R(35199.)>0 THEN WEEKS(13)=R(35199.);
          IF R(35203.)>0 THEN WEEKS(13)=R(35203.);
          IF R(35201.)=0 ! R(35205.)=0 THEN WHYNOT(13)=0;
          ELSE IF R(35206.)>0 THEN WHYNOT(13) =R(35206.);
          ELSE IF R(35202.)>0 THEN WHYNOT(13)=R(35202.);
          ELSE WHYNOT(13)=NA;
          IF R(35227.)<0 ! R(35227.)>998 THEN INDTYP(13)=NA;
          ELSE INDTYP(13)=R(35227.);
          IF R(35228.)<0 ! R(35228.)>994 THEN OCCTYP(13)=NA;
          ELSE OCCTYP(13)=R(35228.);
          IF R(35232.)<0 THEN EMPTYP(13)=NA;
          ELSE EMPTYP(13)=R(35232.);
          IF R(35179.)<1 ! R(35179.)>2 THEN NEWJOB(13)=NA;
          ELSE NEWJOB(13)=R(35179.);
          IF (INDTYP(13)^=NA ! OCCTYP(13)^=NA ! EMPTYP(13)^=NA) & R(35207.)^=1 &
             R(35228.)^=1 THEN EMPLOY(13)=1;
          ELSE EMPLOY(13)=0;
          MILCUR=R(35119.);
          IF R(35149.)>=0 THEN MILCUR=R(35149.);
          IF MILCUR=1 THEN MILITARY(13)=1;
          ELSE MILITARY(13)=NA;

 

1992 VARIABLES

          WEIGHT(14)=R(40063.);
          IF R(37203.)<1 THEN DOING(14)=NA;
          ELSE DOING(14)=R(37203.);
          IF R(37204.)<0 THEN ANYWK(14)=NA;
          ELSE ANYWK(14)=R(37204.);
          IF R(37205.)<1 THEN HRSWK(14)=NA;
          ELSE HRSWK(14)=R(37205.);
          IF R(37213.)>0 THEN HRSWK(14)=R(37213.);
          IF R(37219.)>0 THEN HRSWK(14)=R(37219.);
          IF R(37226.)<0 THEN ABSENT(14)=NA;
          ELSE ABSENT(14)=R(37226.);
          IF R(37227.)<1 THEN WHYOFF(14)=NA;
          ELSE WHYOFF(14)=R(37227.);
          IF R(37236.)<0 THEN LOOK(14)=NA;
          ELSE LOOK(14)=R(37236.);
          DO4WKS(14)=NA;
          IF R(37237.)=1 THEN DO4WKS(14)=1;
          IF R(37238.)>0 ! R(37239.)>0 ! R(37240.)>0 ! R(37241.)>0 ! R(37242.)>0 !
             R(37243.)>0 ! R(37244.)>0 ! R(37245.)>0 THEN DO4WKS(14)=2;
          IF R(37231.)<1 THEN WEEKS(14)=NA;
          ELSE WEEKS(14)=R(37231.);
          IF R(37248.)>0 THEN WEEKS(14)=R(37248.);
          IF R(37252.)>0 THEN WEEKS(14)=R(37252.);
          IF R(37250.)=0 ! R(37254.)=0 THEN WHYNOT(14)=0;
          ELSE IF R(37255.)>0 THEN WHYNOT(14) =R(37255.);
          ELSE IF R(37251.)>0 THEN WHYNOT(14)=R(37251.);
          ELSE WHYNOT(14)=NA;
          IF R(37277.)<0 ! R(37277.)>998 THEN INDTYP(14)=NA;
          ELSE INDTYP(14)=R(37277.);
          IF R(37278.)<0 ! R(37278.)>994 THEN OCCTYP(14)=NA;
          ELSE OCCTYP(14)=R(37278.);
          IF R(37282.)<0 THEN EMPTYP(14)=NA;
          ELSE EMPTYP(14)=R(37282.);
          IF R(37228.)<1 ! R(37228.)>2 THEN NEWJOB(14)=NA;
          ELSE NEWJOB(14)=R(37228.);
          IF (INDTYP(14)^=NA ! OCCTYP(14)^=NA ! EMPTYP(14)^=NA) & R(37256.)^=1 &
             R(37278.)^=1 THEN EMPLOY(14)=1;
          ELSE EMPLOY(14)=0;
          MILCUR=R(37168.);
          IF R(37198.)>=0 THEN MILCUR=R(37198.);
          IF MILCUR=1 THEN MILITARY(14)=1;
          ELSE MILITARY(14)=NA;

 

1993 VARIABLES

    /* IF KEY0002 = -4 THEN */
          WEIGHT(15)=1; /* ELSE WEIGHT(15)=0; */
          ABSENT(15)=-4;
          ANYWK(15)=-4;
          DO4WKS(15)=-4;
          DOING(15)=-4;
          EMPLOY(15)=-4;
          EMPTYP(15)=-4;
          ESR(15)=-4;
          ESRC(15)=-4;
          HRSWK(15)=-4;
          INDTYP(15)=-4;
          LOOK(15)=-4;
          MILITARY(15)=-4;
          NEWJOB(15)=-4;
          OCCTYP(15)=-4;
          WEEKS(15)=-4;
          WHYNOT(15)=-4;
          WHYOFF(15)=-4;
          IF R(41718.)<1 THEN DOING(15)=NA;
          ELSE DOING(15)=R(41718.);
          IF R(41719.)<0 THEN ANYWK(15)=NA;
          ELSE ANYWK(15)=R(41719.);
          IF R(41720.)<1 THEN HRSWK(15)=NA;
          ELSE HRSWK(15)=R(41720.);
          IF R(41727.)>0 THEN HRSWK(15)=R(41727.);
          IF R(41732.)>0 THEN HRSWK(15)=R(41732.);
          IF R(41741.)<0 THEN ABSENT(15)=NA;
          ELSE ABSENT(15)=R(41741.);
          IF R(41742.)<1 THEN WHYOFF(15)=NA;
          ELSE WHYOFF(15)=R(41742.);
          IF R(41751.)<0 THEN LOOK(15)=NA;
          ELSE LOOK(15)=R(41751.);
          DO4WKS(15)=NA;
          IF R(41752.)=1 THEN DO4WKS(15)=1;
          IF R(41763.)>0 THEN DO4WKS(15)=2;
          IF R(41746.)<1 THEN WEEKS(15)=NA;
          ELSE WEEKS(15)=R(41746.);
          IF R(41766.)>0 THEN WEEKS(15)=R(41766.);
          IF R(41770.)>0 THEN WEEKS(15)=R(41770.);
          IF R(41768.)=0 ! R(41772.)=0 THEN WHYNOT(15)=0;
          ELSE IF R(41773.)>0 THEN WHYNOT(15) =R(41773.);
          ELSE IF R(41769.)>0 THEN WHYNOT(15)=R(41769.);
          ELSE WHYNOT(15)=NA;
          IF R(41820.)<0 ! R(41820.)>998 THEN INDTYP(15)=NA;
          ELSE INDTYP(15)=R(41820.);
          IF R(41821.)<0 ! R(41821.)>994 THEN OCCTYP(15)=NA;
          ELSE OCCTYP(15)=R(41821.);
          IF R(41823.)<0 THEN EMPTYP(15)=NA;
          ELSE EMPTYP(15)=R(41823.);
          IF R(41743.)<1 ! R(41743.)>2 THEN NEWJOB(15)=NA;
          ELSE NEWJOB(15)=R(41743.);
          IF (INDTYP(15)^=NA ! OCCTYP(15)^=NA ! EMPTYP(15)^=NA) & R(41774.)^=1 &
             R(41821.)^=1 THEN EMPLOY(15)=1;
          ELSE EMPLOY(15)=0;
          MILCUR=R(41449.);
          IF R(41448.)>=0 THEN MILCUR=R(41448.);
          IF R(41460.)>=0 THEN MILCUR=R(41460.);
          IF MILCUR=1 THEN MILITARY(15)=1;
          ELSE MILITARY(15)=NA;
          DO I=1 TO 15;
             IF MILITARY(I)=1 THEN DO;
                ESR(I)=8;
                GO TO FIN;
             END;
             IF WEIGHT(I)=0 THEN DO;
                ESR(I)=-5;
                GO TO FIN;
             END;
             ESR(I)=7;
             IF DOING(I)^=1 THEN GO TO P6;
             IF HRSWK(I)=NA THEN GO TO P4;
             IF HRSWK(I)>=15 ! EMPTYP(I)^=4 THEN ESR(I)=1;
             GO TO P20000;
             P4: IF EMPLOY(I)=1 THEN ESR(I)=1;
             GO TO P20000;
             P6: ESR(I)=1;
             IF ANYWK(I)^=1 THEN GO TO P11;
             IF HRSWK(I)=NA THEN GO TO P9;
             IF HRSWK(I)<15 & EMPTYP(I)=4 THEN GO TO P61;
             GO TO P62;
             P9: IF EMPLOY(I)=0 THEN GO TO P61;
             GO TO P62;
             P11: IF HRSWK(I)=NA THEN GO TO P15;
             IF EMPLOY(I)=0 THEN GO TO P61;
             IF HRSWK(I)<15 & EMPTYP(I)=4 THEN GO TO P61;
             GO TO P62;
             P15: ESR(I)=7;
             IF DOING(I)=2 THEN GO TO ESR237;
             IF DOING(I)=3 THEN GO TO P21;
             GO TO P37;
             P21: IF ABSENT(I)^=1 THEN GO TO P27;
             GO TO ESR237;
             P27: IF WHYOFF(I)=NA THEN GO TO P32;
             IF WHYOFF(I)=6 ! WHYOFF(I)=7 THEN GO TO P29;
             IF EMPLOY(I)^=0 & EMPTYP(I)^=4 THEN ESR(I)=2;
             GO TO P20000;
             P29: IF WHYNOT(I)<3 THEN ESR(I)=3;
             GO TO P20000;
             P32: IF DO4WKS(I)=1 THEN GO TO P20000;
             IF WHYNOT(I)>2 THEN GO TO P20000;
             IF WEEKS(I)=NA THEN GO TO P33;
             ESR(I)=3;
             GO TO P20000;
             P33: IF DO4WKS(I)>1 ! WHYNOT(I)^=NA THEN ESR(I)=3;
             GO TO P20000;
             P37: ESR(I)=2;
             IF ABSENT(I)^=1 THEN GO TO P43;
             IF WHYOFF(I)=NA THEN GO TO P41;
             IF WHYOFF(I)=6 ! WHYOFF(I)=7 THEN GO TO P39;
             IF EMPTYP(I)=4 THEN GO TO P61;
             GO TO P62;
             P39: IF WHYNOT(I)>2 THEN GO TO P61;
             ESR(I)=3;
             GO TO P62;
             P41: IF EMPLOY(I)=0 ! EMPTYP(I)=4 THEN GO TO P61;
             GO TO P62;
             P43: IF WHYOFF(I)=NA THEN GO TO P48;
             IF WHYOFF(I)=6 ! WHYOFF(I)=7 THEN GO TO P45;
             IF EMPLOY(I)=0 ! EMPTYP(I)=4 THEN GO TO P61;
             GO TO P62;
             P45: IF WEEKS(I)=NA & WHYNOT(I)=NA THEN GO TO P61;
             IF WHYNOT(I)>2 THEN GO TO P61;
             ESR(I)=3;
             GO TO P62;
             P48: ESR(I)=3;
             IF LOOK(I)^=1 THEN GO TO P53;
             IF DO4WKS(I)=1 THEN GO TO P61;
             IF WHYNOT(I)>2 THEN GO TO P61;
             IF DO4WKS(I)^=NA  ! WEEKS(I)^=NA THEN GO TO P62;
             IF WHYNOT(I)=NA THEN GO TO P61;
             GO TO P62;
             P53: IF DO4WKS(I)=1 THEN GO TO P61;
             IF WHYNOT(I)>2 THEN GO TO P61;
             IF DO4WKS(I)=NA THEN GO TO P56;
             IF WEEKS(I)^=NA ! WHYNOT(I)^=NA THEN GO TO P62;
             GO TO P61;
             P56: IF WEEKS(I)=NA ! WHYNOT(I)=NA THEN GO TO P61;
             GO TO P62;
             P61: IF DOING(I)<4 ! DOING(I)>6 THEN GO TO P610;
             ESR(I)=DOING(I);
             GO TO P20000;
             P610: ESR(I)=7;
             GO TO P20000;
             P62: IF DOING(I)=6 THEN DOING(I)=7;
             P20000: GO TO FIN;
             ESR237: IF WHYOFF(I)=NA THEN GO TO P5019;
             IF WHYOFF(I)=6 ! WHYOFF(I)=7 THEN GO TO P5017;
             IF EMPTYP(I)^=-4 THEN ESR(I)=2;
             GO TO FIN;
             P5017: IF WHYNOT(I)>2 THEN GO TO FIN;
             ESR(I)=3;
             GO TO FIN;
             P5019: IF EMPLOY(I)=1 & EMPTYP(I)^=4 THEN ESR(I)=2;
             FIN:;

 

COLLAPSED EMPLOYMENT STATUS RECODE 1984-1993

             IF ESR(I)=-5 THEN ESRC(I)=-5;
             ELSE IF ESR(I)=1 | ESR(I)=2 THEN ESRC(I)=1;
             ELSE IF ESR(I)=3 THEN ESRC(I)=2;
             ELSE IF ESR(I)>=4 & ESR(I)<=7 THEN ESRC(I)=3;
             ELSE IF ESR(I)=8 THEN ESRC(I)=4;
             ELSE ESRC(I)=ESR(I);
          END;

 

CHANGES BETWEEN 1993 AND 1994

NOTE: Users should be aware that the CPS section, on which the creation of Employment Status Recode (ESR) is based, was significantly revised in 1994-96. Hence the 1994-96 ESR variables are created using a different formula than variables in previous years (1979-1993). The formula for the 1994 ESR variable was modeled after that used to compute the MLS (Monthly Labor Status) from the actual Current Population Survey (CPS). The programs for both 1994 and 1996 are included below in their entirety. Those variables identified by reference numbers (R#####.) are those which are included on the 1979-1996 Youth CD-ROM. These are in general, questions answered by or containing valid data for, at least one respondent. The questions identified by question name (Q5????), are those not included on the CD-ROM. These are in general, questions containing no valid data for any respondents. They remain in the formula to have it represented completely. However, the lack of valid data in those variables means that they would have virtually no effect in the formula or on the final value of ESR.

 

1994 VARIABLES

/* The programming for the new 1994 ESR variables is done in SPSS */
 
/* the following lines create the var AGE */
COMPUTE AGE=37
 
/* the following lines construct the var HRACT1 */
DO IF (Q5B2_40A EQ -4)
COMPUTE HRACT1=-4
ELSE IF (Q5B2_41A EQ -1 OR Q5B2_41B EQ -1 OR Q5B2_41C EQ -1 OR Q5B2_41D EQ -1 OR 
                    Q5B2_41A EQ -2 OR Q5B2_41B EQ -2 OR Q5B2_41C EQ -2 OR Q5B2_41D EQ -2)
COMPUTE HRACT1=-2
ELSE IF (Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR Q5B2_41D EQ 995)
COMPUTE HRACT1=995
ELSE IF (Q5B2_40B EQ 1 AND Q5B2_41A NE -4)
COMPUTE HRACT1=Q5B2_41A
ELSE IF (Q5B2_40C EQ 1 AND Q5B2_41B NE -4)
COMPUTE HRACT1=Q5B2_41B
ELSE IF (Q5B2_40D EQ 1 AND Q5B2_41C NE -4)
COMPUTE HRACT1=Q5B2_41C
ELSE IF (Q5B2_40E EQ 1 OR Q5B2_40E EQ 0)
COMPUTE HRACT1=Q5B2_41D
ELSE IF (Q5B_40A EQ -4)
COMPUTE HRACT1=-4
ELSE IF (Q5B_41A EQ -1 OR Q5B_41B EQ -1 OR Q5B_41C EQ -1 OR Q5B_41D EQ -1 OR Q5B_41A EQ -2 OR 
                    Q5B_41B EQ -2 OR Q5B_41C EQ -2 OR Q5B_41D EQ -2)
COMPUTE HRACT1=-2
ELSE IF (Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR Q5B_41D EQ 995)
COMPUTE HRACT1=995
ELSE IF (R(45594.) EQ 1 AND Q5B_41A NE -4)
COMPUTE HRACT1=Q5B_41A
ELSE IF (R(45595.) EQ 1 AND Q5B_41B NE -4)
COMPUTE HRACT1=Q5B_41B
ELSE IF (R(45596.) EQ 1 AND Q5B_41C NE -4)
COMPUTE HRACT1=Q5B_41C
ELSE IF (Q5B_40E EQ 1 OR Q5B_40E EQ 0)
COMPUTE HRACT1=Q5B_41D
ELSE IF (R(45443.) EQ -4)
COMPUTE HRACT1=-4
ELSE IF (R(45448.) EQ -1 OR R(45449.) EQ -1 OR R(45450.) EQ -1 OR R(45451.) EQ -1 OR R(45448.) EQ -2 OR 
                    R(45449.) EQ -2 OR R(45450.) EQ -2 OR R(45451.) EQ -2)
COMPUTE HRACT1=-2
ELSE IF (R(45448.) EQ 995 OR R(45449.) EQ 995 OR R(45450.) EQ 995 OR               R(45451.) EQ 995)
COMPUTE HRACT1=995
ELSE IF (R(45444.) EQ 1 AND R(45448.) NE -4)
COMPUTE HRACT1=R(45448.)
ELSE IF (R(45445.) EQ 1 AND R(45449.) NE -4)
COMPUTE HRACT1=R(45449.)
ELSE IF (R(45446.) EQ 1 AND R(45450.) NE -4)
COMPUTE HRACT1=R(45450.)
ELSE IF (R(45447.) EQ 1 OR R(45447.) EQ 0)
COMPUTE HRACT1=R(45451.)
ELSE
COMPUTE HRACT1=-3
END IF
 
/* the following lines construct the var HRACT2 */
DO IF (Q5B2_42 EQ -4 OR Q5B2_42 EQ 0)
COMPUTE HRACT2=-4
ELSE IF (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2)
COMPUTE HRACT2=-2
ELSE IF (Q5B2_43A EQ 995 OR Q5B2_43B EQ 995)
COMPUTE HRACT2=995
ELSE IF (Q5B2_43 EQ 1)
COMPUTE HRACT2=Q5B2_43A
ELSE IF (Q5B2_42 EQ 1 AND Q5B2_43 EQ 0)
COMPUTE HRACT2=Q5B2_43B
ELSE IF (Q5B_42 EQ -4 OR Q5B_42 EQ 0)
COMPUTE HRACT2=-4
ELSE IF (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2)
COMPUTE HRACT2=-2
ELSE IF (Q5B_43A EQ 995 OR Q5B_43B EQ 995)
COMPUTE HRACT2=995
ELSE IF (Q5B_43 EQ 1)
COMPUTE HRACT2=Q5B_43A
ELSE IF (Q5B_42 EQ 1 AND Q5B_43 EQ 0)
COMPUTE HRACT2=Q5B_43B
ELSE IF (R(45452.) EQ -4 OR R(45452.) EQ 0)
COMPUTE HRACT2=-4
ELSE IF (R(45454.) EQ -1 OR R(45455.) EQ -1 OR R(45454.) EQ -2 OR R(45455.) EQ -2)
COMPUTE HRACT2=-2
ELSE IF (R(45454.) EQ 995 OR R(45455.) EQ 995)
COMPUTE HRACT2=995
ELSE IF (R(45453.) EQ 1)
COMPUTE HRACT2=R(45454.)
ELSE IF (R(45452.) EQ 1 AND R(45453.) EQ 0)
COMPUTE HRACT2=R(45455.)
ELSE 
COMPUTE HRACT2=-3
END IF
 
/* the following lines create the var HRACTT */
DO IF (Q5B2_40A EQ -4)
COMPUTE HRACTT=-4
ELSE IF ((Q5B2_41A EQ -1 OR Q5B2_41B EQ -1 OR Q5B2_41C EQ -1 OR Q5B2_41D EQ -1 OR 
                    Q5B2_41A EQ -2 OR Q5B2_41B EQ -2 OR Q5B2_41C EQ -2 OR Q5B2_41D EQ -2) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2))
COMPUTE HRACTT=-2
ELSE IF ((Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR Q5B2_41D EQ 995) AND 
                    (Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B2_41A EQ -1 OR Q5B2_41B EQ -1 OR Q5B2_41C EQ -1 OR Q5B2_41D EQ -1 OR 
                    Q5B2_41A EQ -2 OR Q5B2_41B EQ -2 OR Q5B2_41C EQ -2 OR Q5B2_41D EQ -2) AND 
                    (Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR Q5B2_41D EQ 995 OR 
                    Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR Q5B2_41D EQ 995) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2))
COMPUTE HRACTT=995
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND Q5B2_41A NE 995) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR 
                    Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41A
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND Q5B2_41B NE 995) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR 
                    Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41B
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND Q5B2_41C NE 995) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR 
                    Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41C
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND Q5B2_41D NE 995) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR 
                    Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41D
ELSE IF ((Q5B2_43A NE -4 AND Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND Q5B2_43A NE 995) AND 
                    (Q5B2_41A EQ -1 OR Q5B2_41A EQ -2 OR Q5B2_41A EQ 995 OR Q5B2_41B EQ -1 OR 
                    Q5B2_41B EQ -2 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ -1 OR Q5B2_41C EQ -2 OR 
                    Q5B2_41C EQ 995 OR Q5B2_41D EQ -1 OR Q5B2_41D EQ -2 OR Q5B2_41D EQ 995))
COMPUTE HRACTT=Q5B2_43A
ELSE IF ((Q5B2_43B NE -4 AND Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND Q5B2_43B NE 995) AND 
                    (Q5B2_41A EQ -1 OR Q5B2_41A EQ -2 OR Q5B2_41A EQ 995 OR Q5B2_41B EQ -1 OR 
                    Q5B2_41B EQ -2 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ -1 OR Q5B2_41C EQ -2 OR 
                    Q5B2_41C EQ 995 OR Q5B2_41D EQ -1 OR Q5B2_41D EQ -2 OR Q5B2_41D EQ 995))
COMPUTE HRACTT=Q5B2_43B
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND Q5B2_41A NE 995) AND 
                    (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41A+Q5B2_43A
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND Q5B2_41A NE 995) AND 
                    (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41A+Q5B2_43B
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND Q5B2_41B NE 995) AND 
                    (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41B+Q5B2_43A
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND Q5B2_41B NE 995) AND 
                    (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41B+Q5B2_43B
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND Q5B2_41C NE 995) AND 
                    (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41C+Q5B2_43A
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND Q5B2_41C NE 995) AND 
                    (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41C+Q5B2_43B
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND Q5B2_41D NE 995) AND 
                    (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41D+Q5B2_43A
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND Q5B2_41D NE 995) AND 
                    (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41D+Q5B2_43B
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND Q5B2_41A NE 995) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41A
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND Q5B2_41B NE 995) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41B
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND Q5B2_41C NE 995) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41C
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND Q5B2_41D NE 995) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41D
ELSE IF ((Q5B2_41A EQ -1 OR Q5B2_41A EQ -2 OR Q5B2_41B EQ -1 OR Q5B2_41B EQ -2 OR 
                    Q5B2_41C EQ -1 OR Q5B2_41C EQ -2 OR Q5B2_41D EQ -1 OR Q5B2_41D EQ -2) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=-2
ELSE IF ((Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR Q5B2_41D EQ 995) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=995
ELSE IF (Q5B_40A EQ -4)
COMPUTE HRACTT=-4
ELSE IF ((Q5B_41A EQ -1 OR Q5B_41B EQ -1 OR Q5B_41C EQ -1 OR Q5B_41D EQ -1 OR Q5B_41A EQ -2 OR 
                    Q5B_41B EQ -2 OR Q5B_41C EQ -2 OR Q5B_41D EQ -2) AND (Q5B_43A EQ -1 OR 
                    Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2))
COMPUTE HRACTT=-2
ELSE IF ((Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR Q5B_41D EQ 995) AND 
                    (Q5B_43A EQ 995 OR Q5B_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B_41A EQ -1 OR Q5B_41B EQ -1 OR Q5B_41C EQ -1 OR Q5B_41D EQ -1 OR Q5B_41A EQ -2 OR 
                    Q5B_41B EQ -2 OR Q5B_41C EQ -2 OR Q5B_41D EQ -2) AND (Q5B_43A EQ 995 OR 
                    Q5B_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR Q5B_41D EQ 995 OR 
                    Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR Q5B_41D EQ 995) AND 
                    (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2))
COMPUTE HRACTT=995
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND Q5B_41A NE 995) AND 
                    (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR 
                    Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41A
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND Q5B_41B NE 995) AND 
                    (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR 
                    Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41B
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND Q5B_41C NE 995) AND 
                    (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR
                    Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41C
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND Q5B_41D NE 995) AND 
                    (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR 
                    Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41D
ELSE IF ((Q5B_43A NE -4 AND Q5B_43A NE -1 AND Q5B_43A NE -2 AND Q5B_43A NE 995) AND 
                    (Q5B_41A EQ -1 OR Q5B_41A EQ -2 OR Q5B_41A EQ 995 OR Q5B_41B EQ -1 OR Q5B_41B EQ -2 OR 
                    Q5B_41B EQ 995 OR Q5B_41C EQ -1 OR Q5B_41C EQ -2 OR Q5B_41C EQ 995 OR 
                    Q5B_41D EQ -1 OR Q5B_41D EQ -2 OR Q5B_41D EQ 995))
COMPUTE HRACTT=Q5B_43A
ELSE IF ((Q5B_43B NE -4 AND Q5B_43B NE -1 AND Q5B_43B NE -2 AND Q5B_43B NE 995) AND 
                    (Q5B_41A EQ -1 OR Q5B_41A EQ -2 OR Q5B_41A EQ 995 OR Q5B_41B EQ -1 OR Q5B_41B EQ -2 OR 
                    Q5B_41B EQ 995 OR Q5B_41C EQ -1 OR Q5B_41C EQ -2 OR Q5B_41C EQ 995 OR 
                    Q5B_41D EQ -1 OR Q5B_41D EQ -2 OR Q5B_41D EQ 995))
COMPUTE HRACTT=Q5B_43B
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND Q5B_41A NE 995) AND 
                    (Q5B_43A NE -1 AND Q5B_43A NE -2 AND Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41A+Q5B_43A
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND Q5B_41A NE 995) AND 
                    (Q5B_43B NE -1 AND Q5B_43B NE -2 AND Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41A+Q5B_43B
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND Q5B_41B NE 995) AND 
                    (Q5B_43A NE -1 AND Q5B_43A NE -2 AND Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41B+Q5B_43A
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND Q5B_41B NE 995) AND 
                    (Q5B_43B NE -1 AND Q5B_43B NE -2 AND Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41B+Q5B_43B
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND Q5B_41C NE 995) AND 
                    (Q5B_43A NE -1 AND Q5B_43A NE -2 AND Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41C+Q5B_43A
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND Q5B_41C NE 995) AND 
                    (Q5B_43B NE -1 AND Q5B_43B NE -2 AND Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41C+Q5B_43B
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND Q5B_41D NE 995) AND 
                    (Q5B_43A NE -1 AND Q5B_43A NE -2 AND Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41D+Q5B_43A
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND Q5B_41D NE 995) AND 
                    (Q5B_43B NE -1 AND Q5B_43B NE -2 AND Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41D+Q5B_43B
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND Q5B_41A NE 995) AND 
                    Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41A
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND Q5B_41B NE 995) AND 
                    Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41B
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND Q5B_41C NE 995) AND 
                    Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41C
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND Q5B_41D NE 995) AND 
                    Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41D
ELSE IF ((Q5B_41A EQ -1 OR Q5B_41A EQ -2 OR Q5B_41B EQ -1 OR Q5B_41B EQ -2 OR Q5B_41C EQ -1 OR
                    Q5B_41C EQ -2 OR Q5B_41D EQ -1 OR Q5B_41D EQ -2) AND Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=-2
ELSE IF ((Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR Q5B_41D EQ 995) AND 
                    Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=995
ELSE IF (R(45443.) EQ -4)
COMPUTE HRACTT=-4
ELSE IF ((R(45448.) EQ -1 OR R(45449.) EQ -1 OR R(45450.) EQ -1 OR R(45451.) EQ -1 OR R(45448.) EQ -2 OR 
                    R(45449.) EQ -2 OR R(45450.) EQ -2 OR R(45451.) EQ -2) AND (R(45454.) EQ -1 OR 
                    R(45455.) EQ -1 OR R(45454.) EQ -2 OR R(45455.) EQ -2))
COMPUTE HRACTT=-2
ELSE IF ((R(45448.) EQ 995 OR R(45449.) EQ 995 OR R(45450.) EQ 995 OR R(45451.) EQ 995) AND 
                    (R(45454.) EQ 995 OR R(45455.) EQ 995))
COMPUTE HRACTT=995
ELSE IF ((R(45448.) EQ -1 OR R(45449.) EQ -1 OR R(45450.) EQ -1 OR R(45451.) EQ -1 OR R(45448.) EQ -2 OR 
                    R(45449.) EQ -2 OR R(45450.) EQ -2 OR R(45451.) EQ -2) AND (R(45454.) EQ 995 OR 
                    R(45455.) EQ 995))
COMPUTE HRACTT=995
ELSE IF ((R(45448.) EQ 995 OR R(45449.) EQ 995 OR R(45450.) EQ 995 OR R(45451.) EQ 995 OR 
                    R(45448.) EQ 995 OR R(45449.) EQ 995 OR R(45450.) EQ 995 OR R(45451.) EQ 995) AND 
                    (R(45454.) EQ -1 OR R(45455.) EQ -1 OR R(45454.) EQ -2 OR R(45455.) EQ -2))
COMPUTE HRACTT=995
ELSE IF ((R(45448.) NE -4 AND R(45448.) NE -1 AND R(45448.) NE -2 AND R(45448.) NE 995) AND 
                    (R(45454.) EQ -1 OR R(45455.) EQ -1 OR R(45454.) EQ -2 OR R(45455.) EQ -2 OR 
                    R(45454.) EQ 995 OR R(45455.) EQ 995))
COMPUTE HRACTT=R(45448.)
ELSE IF ((R(45449.) NE -4 AND R(45449.) NE -1 AND R(45449.) NE -2 AND R(45449.) NE 995) AND 
                    (R(45454.) EQ -1 OR R(45455.) EQ -1 OR R(45454.) EQ -2 OR R(45455.) EQ -2 OR 
                    R(45454.) EQ 995 OR R(45455.) EQ 995))
COMPUTE HRACTT=R(45449.)
ELSE IF ((R(45450.) NE -4 AND R(45450.) NE -1 AND R(45450.) NE -2 AND R(45450.) NE 995) AND 
                    (R(45454.) EQ -1 OR R(45455.) EQ -1 OR R(45454.) EQ -2 OR R(45455.) EQ -2 OR 
                    R(45454.) EQ 995 OR R(45455.) EQ 995))
COMPUTE HRACTT=R(45450.)
ELSE IF ((R(45451.) NE -4 AND R(45451.) NE -1 AND R(45451.) NE -2 AND R(45451.) NE 995) AND 
                    (R(45454.) EQ -1 OR R(45455.) EQ -1 OR R(45454.) EQ -2 OR R(45455.) EQ -2 OR 
                    R(45454.) EQ 995 OR R(45455.) EQ 995))
COMPUTE HRACTT=R(45451.)
ELSE IF ((R(45454.) NE -4 AND R(45454.) NE -1 AND R(45454.) NE -2 AND R(45454.) NE 995) AND 
                    (R(45448.) EQ -1 OR R(45448.) EQ -2 OR R(45448.) EQ 995 OR R(45449.) EQ -1 OR 
                    R(45449.) EQ -2 OR R(45449.) EQ 995 OR R(45450.) EQ -1 OR R(45450.) EQ -2 OR 
                    R(45450.) EQ 995 OR R(45451.) EQ -1 OR R(45451.) EQ -2 OR R(45451.) EQ 995))
COMPUTE HRACTT=R(45454.)
ELSE IF ((R(45455.) NE -4 AND R(45455.) NE -1 AND R(45455.) NE -2 AND R(45455.) NE 995) AND 
                    R(45448.) EQ -1 OR R(45448.) EQ -2 OR R(45448.) EQ 995 OR R(45449.) EQ -1 OR R(45449.) EQ -2 OR 
                    R(45449.) EQ 995 OR R(45450.) EQ -1 OR R(45450.) EQ -2 OR R(45450.) EQ 995 OR 
                    R(45451.) EQ -1 OR R(45451.) EQ -2 OR R(45451.) EQ 995))
COMPUTE HRACTT=R(45455.)
ELSE IF ((R(45448.) NE -4 AND R(45448.) NE -1 AND R(45448.) NE -2 AND R(45448.) NE 995) AND 
                    (R(45454.) NE -1 AND R(45454.) NE -2 AND R(45454.) NE 995 AND R(45454.) NE -4)) 
COMPUTE HRACTT=R(45448.)+R(45454.)
ELSE IF ((R(45448.) NE -4 AND R(45448.) NE -1 AND R(45448.) NE -2 AND R(45448.) NE 995) AND 
                    (R(45455.) NE -1 AND R(45455.) NE -2 AND R(45455.) NE 995 AND R(45455.) NE -4)) 
COMPUTE HRACTT=R(45448.)+R(45455.)
ELSE IF ((R(45449.) NE -4 AND R(45449.) NE -1 AND R(45449.) NE -2 AND R(45449.) NE 995) AND 
                    (R(45454.) NE -1 AND R(45454.) NE -2 AND R(45454.) NE 995 AND R(45454.) NE -4)) 
COMPUTE HRACTT=R(45449.)+R(45454.)
ELSE IF ((R(45449.) NE -4 AND R(45449.) NE -1 AND R(45449.) NE -2 AND R(45449.) NE 995) AND 
                    (R(45455.) NE -1 AND R(45455.) NE -2 AND R(45455.) NE 995 AND R(45455.) NE -4)) 
COMPUTE HRACTT=R(45449.)+R(45455.)
ELSE IF ((R(45450.) NE -4 AND R(45450.) NE -1 AND R(45450.) NE -2 AND R(45450.) NE 995) AND 
                    (R(45454.) NE -1 AND R(45454.) NE -2 AND R(45454.) NE 995 AND R(45454.) NE -4)) 
COMPUTE HRACTT=R(45450.)+R(45454.)
ELSE IF ((R(45450.) NE -4 AND R(45450.) NE -1 AND R(45450.) NE -2 AND R(45450.) NE 995) AND 
                    (R(45455.) NE -1 AND R(45455.) NE -2 AND R(45455.) NE 995 AND R(45455.) NE -4)) 
COMPUTE HRACTT=R(45450.)+R(45455.)
ELSE IF ((R(45451.) NE -4 AND R(45451.) NE -1 AND R(45451.) NE -2 AND R(45451.) NE 995) AND 
                    (R(45454.) NE -1 AND R(45454.) NE -2 AND R(45454.) NE 995 AND R(45454.) NE -4)) 
COMPUTE HRACTT=R(45451.)+R(45454.)
ELSE IF ((R(45451.) NE -4 AND R(45451.) NE -1 AND R(45451.) NE -2 AND R(45451.) NE 995) AND 
                    (R(45455.) NE -1 AND R(45455.) NE -2 AND R(45455.) NE 995 AND R(45455.) NE -4)) 
COMPUTE HRACTT=R(45451.)+R(45455.)
ELSE IF ((R(45448.) NE -4 AND R(45448.) NE -1 AND R(45448.) NE -2 AND R(45448.) NE 995) AND 
                    R(45454.) EQ -4 AND R(45455.) EQ -4)
COMPUTE HRACTT=R(45448.)
ELSE IF ((R(45449.) NE -4 AND R(45449.) NE -1 AND R(45449.) NE -2 AND R(45449.) NE 995) AND 
                    R(45454.) EQ -4 AND R(45455.) EQ -4)
COMPUTE HRACTT=R(45449.)
ELSE IF ((R(45450.) NE -4 AND R(45450.) NE -1 AND R(45450.) NE -2 AND R(45450.) NE 995) AND 
                    R(45454.) EQ -4 AND R(45455.) EQ -4)
COMPUTE HRACTT=R(45450.)
ELSE IF ((R(45451.) NE -4 AND R(45451.) NE -1 AND R(45451.) NE -2 AND R(45451.) NE 995) AND 
                    R(45454.) EQ -4 AND R(45455.) EQ -4)
COMPUTE HRACTT=R(45451.)
ELSE IF ((R(45448.) EQ -1 OR R(45448.) EQ -2 OR R(45449.) EQ -1 OR R(45449.) EQ -2 OR R(45450.) EQ -1 OR
                     R(45450.) EQ -2 OR R(45451.) EQ -1 OR R(45451.) EQ -2) AND R(45454.) EQ -4 AND R(45455.) EQ -4)
COMPUTE HRACTT=-2
ELSE IF ((R(45448.) EQ 995 OR R(45449.) EQ 995 OR R(45450.) EQ 995 OR R(45451.) EQ 995) AND 
                    R(45454.) EQ -4 AND R(45455.) EQ -4)
COMPUTE HRACTT=995
ELSE 
COMPUTE HRACTT=-3
END IF
 
/* the following lines creates the var BUS2 */
DO IF (R(45368.) EQ -4)
COMPUTE BUS2=-4
ELSE IF (R(45368.) EQ -1)
COMPUTE BUS2=-1
ELSE IF (R(45368.) EQ -2)
COMPUTE BUS2=-2
ELSE IF (R(45369.) EQ -1 OR R(45370.) EQ -1)
COMPUTE BUS2=-1
ELSE IF (R(45369.) EQ -2 OR R(45370.) EQ -2)
COMPUTE BUS2=-2
ELSE IF (R(45369.) EQ 1 OR R(45370.) EQ 1)
COMPUTE BUS2=1
ELSE IF (R(45370.) EQ 0)
COMPUTE BUS2=2  /* this should normally be 0 */
ELSE 
COMPUTE BUS2=-3
END IF
 
/* the following lines create the var HRUSL1 */
DO IF (R(45665.) EQ -4)
COMPUTE HRUSL1=-4
ELSE IF (R(45666.) EQ -1 OR R(45667.) EQ -1 OR R(45666.) EQ -2 OR R(45667.) EQ -2)
COMPUTE HRUSL1=-2
ELSE IF (R(45666.) EQ 995 OR R(45667.) EQ 995)
COMPUTE HRUSL1=995
ELSE IF (R(45666.) EQ 1)
COMPUTE HRUSL1=Q5B2_26B
ELSE IF (R(45667.) EQ 1)
COMPUTE HRUSL1=Q5B2_26D
ELSE IF (R(45582.) EQ -4)
COMPUTE HRUSL1=-4
ELSE IF (Q5B_26A EQ -1 OR R(45583.) EQ -1 OR Q5B_26A EQ -2 OR R(45583.) EQ -2)
COMPUTE HRUSL1=-2
ELSE IF (Q5B_26A EQ 995 OR R(45583.) EQ 995)
COMPUTE HRUSL1=995
ELSE IF (Q5B_26A EQ 1)
COMPUTE HRUSL1=Q5B_26B
ELSE IF (R(45583.) EQ 1)
COMPUTE HRUSL1=R(45584.)
ELSE IF (R(45399.) EQ -4)
COMPUTE HRUSL1=-4
ELSE IF (R(45400.) EQ -1 OR R(45402.) EQ -1 OR R(45400.) EQ -2 OR R(45402.) EQ -2)
COMPUTE HRUSL1=-2
ELSE IF (R(45400.) EQ 995 OR R(45402.) EQ 995)
COMPUTE HRUSL1=995
ELSE IF (R(45400.) EQ 1)
COMPUTE HRUSL1=R(45401.)
ELSE IF (R(45402.) EQ 1)
COMPUTE HRUSL1=R(45403.)
ELSE 
COMPUTE HRUSL1=-3
END IF
 
/* the following lines create the var HRUSL2 */
DO IF (Q5B2_28A EQ -4)
COMPUTE HRUSL2=-4
ELSE IF (Q5B2_28B EQ -1 OR Q5B2_28D EQ -1 OR Q5B2_28B EQ -2 OR Q5B2_28D EQ -2)
COMPUTE HRUSL2=-2
ELSE IF (Q5B2_28B EQ 995 OR Q5B2_28D EQ 995)
COMPUTE HRUSL2=995
ELSE IF (Q5B2_28B EQ 1)
COMPUTE HRUSL2=Q5B2_28C
ELSE IF (Q5B2_28D EQ 1)
COMPUTE HRUSL2=Q5B2_28E
ELSE IF (Q5B_28A EQ -4)
COMPUTE HRUSL2=-4
ELSE IF (Q5B_28B EQ -1 OR Q5B_28D EQ -1 OR Q5B_28B EQ -2 OR Q5B_28D EQ -2)
COMPUTE HRUSL2=-2
ELSE IF (Q5B_28B EQ 995 OR Q5B_28D EQ 995)
COMPUTE HRUSL2=995
ELSE IF (Q5B_28B EQ 1)
COMPUTE HRUSL2=Q5B_28C
ELSE IF (Q5B_28D EQ 1)
COMPUTE HRUSL2=Q5B_28E
ELSE IF (R(45405.) EQ -4)
COMPUTE HRUSL2=-4
ELSE IF (R(45406.) EQ -1 OR R(45408.) EQ -1 OR R(45406.) EQ -2 OR R(45408.) EQ -2)
COMPUTE HRUSL2=-2
ELSE IF (R(45406.) EQ 995 OR R(45408.) EQ 995)
COMPUTE HRUSL2=995
ELSE IF (R(45406.) EQ 1)
COMPUTE HRUSL2=Q5_28C
ELSE IF (R(45408.) EQ 1)
COMPUTE HRUSL2=Q5_28E
ELSE 
COMPUTE HRUSL2=-3
END IF 
 
/* the following lines create the var HRUSLT */
DO IF (R(45665.) EQ -4)
COMPUTE HRUSLT=-4
ELSE IF ((R(45666.) EQ -1 OR R(45667.) EQ -1 OR R(45666.) EQ -2 OR R(45667.) EQ -2) AND 
                    (Q5B2_28B EQ -1 OR Q5B2_28D EQ -1 OR Q5B2_28B EQ -2 OR Q5B2_28D EQ -2))
COMPUTE HRUSLT=-2
ELSE IF ((R(45666.) EQ 995 OR R(45667.) EQ 995) AND (Q5B2_28B EQ 995 OR Q5B2_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((R(45666.) EQ -1 OR R(45667.) EQ -1 OR R(45666.) EQ -2 OR R(45667.) EQ -2) AND 
                    (Q5B2_28B EQ 995 OR Q5B2_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((R(45666.) EQ 995 OR R(45667.) EQ 995) AND (Q5B2_28B EQ -1 OR Q5B2_28D EQ -1 OR 
                    Q5B2_28B EQ -2 OR Q5B2_28D EQ -2))
COMPUTE HRUSLT=995
ELSE IF ((R(45666.) EQ 995 OR R(45667.) EQ 995) AND Q5B2_27 NE 1)
COMPUTE HRUSLT=995
ELSE IF ((R(45666.) EQ -1 OR R(45667.) EQ -1 OR R(45666.) EQ -2 OR R(45667.) EQ -2) AND Q5B2_27 NE 1)
COMPUTE HRUSLT=-2
ELSE IF (R(45666.) EQ 1 AND (Q5B2_28B EQ -1 OR Q5B2_28B EQ -2 OR Q5B2_28B EQ 995 OR 
                    Q5B2_28D EQ -1 OR Q5B2_28D EQ -2 OR Q5B2_28D EQ 995))
COMPUTE HRUSLT=Q5B2_26B
ELSE IF (R(45667.) EQ 1 AND (Q5B2_28B EQ -1 OR Q5B2_28B EQ -2 OR Q5B2_28B EQ 995 OR 
                    Q5B2_28D EQ -1 OR Q5B2_28D EQ -2 OR Q5B2_28D EQ 995))
COMPUTE HRUSLT=Q5B2_26D
ELSE IF (Q5B2_28B EQ 1 AND (R(45666.) EQ -1 OR R(45666.) EQ -2 OR R(45666.) EQ 995 OR 
                    R(45667.) EQ -1 OR R(45667.) EQ -2 OR R(45667.) EQ 995))
COMPUTE HRUSLT=Q5B2_28C
ELSE IF (Q5B2_28D EQ 1 AND (R(45666.) EQ -1 OR R(45666.) EQ -2 OR R(45666.) EQ 995 OR 
                    R(45667.) EQ -1 OR R(45667.) EQ -2 OR R(45667.) EQ 995))
COMPUTE HRUSLT=Q5B2_28E
ELSE IF (R(45666.) EQ 1 AND Q5B2_27 NE 1)
COMPUTE HRUSLT=Q5B2_26B
ELSE IF (R(45667.) EQ 1 AND Q5B2_27 NE 1)
COMPUTE HRUSLT=Q5B2_26D
ELSE IF (R(45666.) EQ 1 AND Q5B2_28B EQ 1)
COMPUTE HRUSLT=Q5B2_26B+Q5B2_28C
ELSE IF (R(45666.) EQ 1 AND Q5B2_28D EQ 1)
COMPUTE HRUSLT=Q5B2_26B+Q5B2_28E
ELSE IF (R(45667.) EQ 1 AND Q5B2_28B EQ 1)
COMPUTE HRUSLT=Q5B2_26D+Q5B2_28C
ELSE IF (R(45667.) EQ 1 AND Q5B2_28D EQ 1)
COMPUTE HRUSLT=R(45667.)+Q5B2_28E
ELSE IF (R(45582.) EQ -4)
COMPUTE HRUSLT=-4
ELSE IF ((Q5B_26A EQ -1 OR R(45583.) EQ -1 OR Q5B_26A EQ -2 OR R(45583.) EQ -2) AND 
                    (Q5B_28B EQ -1 OR Q5B_28D EQ -1 OR Q5B_28B EQ -2 OR Q5B_28D EQ -2))
COMPUTE HRUSLT=-2
ELSE IF ((Q5B_26A EQ 995 OR R(45583.) EQ 995) AND (Q5B_28B EQ 995 OR Q5B_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ -1 OR R(45583.) EQ -1 OR Q5B_26A EQ -2 OR R(45583.) EQ -2) AND 
                    (Q5B_28B EQ 995 OR Q5B_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ 995 OR R(45583.) EQ 995) AND (Q5B_28B EQ -1 OR Q5B_28D EQ -1 OR 
                    Q5B_28B EQ -2 OR Q5B_28D EQ -2))
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ 995 OR R(45583.) EQ 995) AND R(45585.) NE 1)
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ -1 OR R(45583.) EQ -1 OR Q5B_26A EQ -2 OR R(45583.) EQ -2) AND R(45585.) NE 1)
COMPUTE HRUSLT=-2
ELSE IF (Q5B_26A EQ 1 AND (Q5B_28B EQ -1 OR Q5B_28B EQ -2 OR Q5B_28B EQ 995 OR 
                    Q5B_28D EQ -1 OR Q5B_28D EQ -2 OR Q5B_28D EQ 995))
COMPUTE HRUSLT=Q5B_26B
ELSE IF (R(45583.) EQ 1 AND (Q5B_28B EQ -1 OR Q5B_28B EQ -2 OR Q5B_28B EQ 995 OR 
                    Q5B_28D EQ -1 OR Q5B_28D EQ -2 OR Q5B_28D EQ 995))
COMPUTE HRUSLT=R(45584.)
ELSE IF (Q5B_28B EQ 1 AND (Q5B_26A EQ -1 OR Q5B_26A EQ -2 OR Q5B_26A EQ 995 OR 
                    R(45583.) EQ -1 OR R(45583.) EQ -2 OR R(45583.) EQ 995))
COMPUTE HRUSLT=Q5B_28C
ELSE IF (Q5B_28D EQ 1 AND (Q5B_26A EQ -1 OR Q5B_26A EQ -2 OR Q5B_26A EQ 995 OR 
                    R(45583.) EQ -1 OR R(45583.) EQ -2 OR R(45583.) EQ 995))
COMPUTE HRUSLT=Q5B_28E
ELSE IF (Q5B_26A EQ 1 AND R(45585.) NE 1)
COMPUTE HRUSLT=Q5B_26B
ELSE IF (R(45583.) EQ 1 AND R(45585.) NE 1)
COMPUTE HRUSLT=R(45584.)
ELSE IF (Q5B_26A EQ 1 AND Q5B_28B EQ 1)
COMPUTE HRUSLT=Q5B_26B+Q5B_28C
ELSE IF (Q5B_26A EQ 1 AND Q5B_28D EQ 1)
COMPUTE HRUSLT=Q5B_26B+Q5B_28E
ELSE IF (R(45583.) EQ 1 AND Q5B_28B EQ 1)
COMPUTE HRUSLT=R(45584.)+Q5B_28C
ELSE IF (R(45583.) EQ 1 AND Q5B_28D EQ 1)
COMPUTE HRUSLT=R(45583.)+Q5B_28E
ELSE IF (R(45399.) EQ -4)
COMPUTE HRUSLT=-4
ELSE IF ((R(45400.) EQ -1 OR R(45402.) EQ -1 OR R(45400.) EQ -2 OR R(45402.) EQ -2) AND 
                    (R(45406.) EQ -1 OR R(45408.) EQ -1 OR R(45406.) EQ -2 OR R(45408.) EQ -2))
COMPUTE HRUSLT=-2
ELSE IF ((R(45400.) EQ 995 OR R(45402.) EQ 995) AND (R(45406.) EQ 995 OR R(45408.) EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((R(45400.) EQ -1 OR R(45402.) EQ -1 OR R(45400.) EQ -2 OR R(45402.) EQ -2) AND 
                    (R(45406.) EQ 995 OR R(45408.) EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((R(45400.) EQ 995 OR R(45402.) EQ 995) AND (R(45406.) EQ -1 OR R(45408.) EQ -1 OR 
                    R(45406.) EQ -2 OR R(45408.) EQ -2))
COMPUTE HRUSLT=995
ELSE IF ((R(45400.) EQ 995 OR R(45402.) EQ 995) AND R(45404.) NE 1)
COMPUTE HRUSLT=995
ELSE IF ((R(45400.) EQ -1 OR R(45402.) EQ -1 OR R(45400.) EQ -2 OR R(45402.) EQ -2) AND R(45404.) NE 1)
COMPUTE HRUSLT=-2
ELSE IF (R(45400.) EQ 1 AND (R(45406.) EQ -1 OR R(45406.) EQ -2 OR R(45406.) EQ 995 OR 
                    R(45408.) EQ -1 OR R(45408.) EQ -2 OR R(45408.) EQ 995))
COMPUTE HRUSLT=R(45401.)
ELSE IF (R(45402.) EQ 1 AND (R(45406.) EQ -1 OR R(45406.) EQ -2 OR R(45406.) EQ 995 OR 
                    R(45408.) EQ -1 OR R(45408.) EQ -2 OR R(45408.) EQ 995))
COMPUTE HRUSLT=R(45403.)
ELSE IF (R(45406.) EQ 1 AND (R(45400.) EQ -1 OR R(45400.) EQ -2 OR R(45400.) EQ 995 OR 
                    R(45402.) EQ -1 OR R(45402.) EQ -2 OR R(45402.) EQ 995))
COMPUTE HRUSLT=R(45407.)
ELSE IF (R(45408.) EQ 1 AND (R(45400.) EQ -1 OR R(45400.) EQ -2 OR R(45400.) EQ 995 OR 
                    R(45402.) EQ -1 OR R(45402.) EQ -2 OR R(45402.) EQ 995))
COMPUTE HRUSLT=R(45409.)
ELSE IF (R(45400.) EQ 1 AND R(45404.) NE 1)
COMPUTE HRUSLT=R(45401.)
ELSE IF (R(45402.) EQ 1 AND R(45404.) NE 1)
COMPUTE HRUSLT=R(45403.)
ELSE IF (R(45400.) EQ 1 AND R(45406.) EQ 1)
COMPUTE HRUSLT=R(45401.)+R(45407.)
ELSE IF (R(45400.) EQ 1 AND R(45408.) EQ 1)
COMPUTE HRUSLT=R(45401.)+R(45409.)
ELSE IF (R(45402.) EQ 1 AND R(45406.) EQ 1)
COMPUTE HRUSLT=R(45403.)+R(45407.)
ELSE IF (R(45402.) EQ 1 AND R(45408.) EQ 1)
COMPUTE HRUSLT=R(45402.)+R(45409.)
ELSE 
COMPUTE HRUSLT=-3
END IF
 
/* the following lines create the var HRFTPT */
DO IF (Q5B2_30C EQ -4)
COMPUTE HRFTPT=-4
ELSE IF (Q5B2_30F EQ -1 OR Q5B2_30G EQ -1 OR Q5B2_30H EQ -1 OR Q5B2_30I EQ -1)
COMPUTE HRFTPT=-1
ELSE IF (Q5B2_30F EQ -2 OR Q5B2_30G EQ -2 OR Q5B2_30H EQ -2 OR Q5B2_30I EQ -2)
COMPUTE HRFTPT=-2
ELSE IF (Q5B2_30F NE -4)
COMPUTE HRFTPT=Q5B2_30F
ELSE IF (Q5B2_30G NE -4)
COMPUTE HRFTPT=Q5B2_30G
ELSE IF (Q5B2_30H NE -4)
COMPUTE HRFTPT=Q5B2_30H
ELSE IF (Q5B2_30I NE -4)
COMPUTE HRFTPT=Q5B2_30I
ELSE IF (Q5B_30C EQ -4)
COMPUTE HRFTPT=-4
ELSE IF (Q5B_30F EQ -1 OR Q5B_30G EQ -1 OR Q5B_30H EQ -1 OR Q5B_30I EQ -1)
COMPUTE HRFTPT=-1
ELSE IF (Q5B_30F EQ -2 OR Q5B_30G EQ -2 OR Q5B_30H EQ -2 OR Q5B_30I EQ -2)
COMPUTE HRFTPT=-2
ELSE IF (Q5B_30F NE -4)
COMPUTE HRFTPT=Q5B_30F
ELSE IF (Q5B_30G NE -4)
COMPUTE HRFTPT=Q5B_30G
ELSE IF (Q5B_30H NE -4)
COMPUTE HRFTPT=Q5B_30H
ELSE IF (Q5B_30I NE -4)
COMPUTE HRFTPT=Q5B_30I
ELSE IF (R(45420.) EQ -4)
COMPUTE HRFTPT=-4
ELSE IF (Q5_30F EQ -1 OR R(45423.) EQ -1 OR R(45424.) EQ -1 OR R(45425.) EQ -1)
COMPUTE HRFTPT=-1
ELSE IF (Q5_30F EQ -2 OR R(45423.) EQ -2 OR R(45424.) EQ -2 OR R(45425.) EQ -2)
COMPUTE HRFTPT=-2
ELSE IF (Q5_30F NE -4)
COMPUTE HRFTPT=Q5_30F
ELSE IF (R(45423.) NE -4)
COMPUTE HRFTPT=R(45423.)
ELSE IF (R(45424.) NE -4)
COMPUTE HRFTPT=R(45424.)
ELSE IF (R(45425.) NE -4)
COMPUTE HRFTPT=R(45425.)
ELSE
COMPUTE HRFTPT=-3
END IF 
 
/* the following lines create the var HRWANT */
DO IF (Q5B2_33 NE -4)
COMPUTE HRWANT=Q5B2_33
ELSE IF (Q5B_33 NE -4)
COMPUTE HRWANT=Q5B_33
ELSE 
COMPUTE HRWANT=R(45436.)
END IF
 
/* the following lines create the var HRRSN1 */
DO IF (Q5B2_34 NE -4)
COMPUTE HRRSN1=Q5B2_34
ELSE IF (Q5B_34 NE -4)
COMPUTE HRRSN1=Q5B_34
ELSE
COMPUTE HRRSN1=R(45437.)
END IF
 
/* the following lines create the var HRCK7 */
COMPUTE HRCK7=-4
DO IF ((BUS2 EQ 2 OR BUS2 EQ -2 OR BUS2 EQ -1) AND (HRACT1 LT 15 OR HRACT1 EQ -2))
COMPUTE HRCK7=1
ELSE IF ((BUS2 EQ 2 OR BUS2 EQ -2 OR BUS2 EQ -1) AND HRACT1 GE 15)
COMPUTE HRCK7=2
ELSE IF ((HRUSLT GE 35 OR HRFTPT EQ 1) AND HRACTT LT 35 AND (HRACT1 NE -1 OR 
                    HRACT1 NE -2 OR HRACT2 NE -1 OR HRACT2 NE -2)) 
COMPUTE HRCK7=3
ELSE IF (HRWANT EQ 1 AND HRACTT LT 35 AND (HRRSN1 EQ 1 OR HRRSN1 EQ 2 OR HRRSN1 EQ 3))
COMPUTE HRCK7=4
ELSE 
COMPUTE HRCK7=5
END IF 
 
/* the following lines create the var ABSOT */
DO IF (HRACT1 EQ 0 AND HRACT2 EQ 0)
COMPUTE ABSOT=1
ELSE
COMPUTE ABSOT=0
END IF
 
/* the following lines create the var HRCK6 */
COMPUTE HRCK6=-4
DO IF ((HRACT1 EQ 0 AND HRACT2 EQ 0) AND (BUS2 EQ 2 OR BUS2 EQ -1 OR BUS2 EQ -2))
COMPUTE HRCK6=1
ELSE IF (ABSOT EQ 1)
COMPUTE HRCK6=2
ELSE 
COMPUTE HRCK6=3
END IF
 
/* the following lines create the var WK */
COMPUTE WK=-4
DO IF (R(45364.) NE -4)
COMPUTE WK=R(45364.)
ELSE IF (R(45365.) NE -4)
COMPUTE WK=R(45365.)
END IF
 
/* the following lines create the var RETOT */
DO IF (WK EQ 3)
COMPUTE RETOT=1
ELSE
COMPUTE RETOT=0
END IF
 
/* the following lines rename the vars */
COMPUTE BUS1=R(45367.)
COMPUTE RET1=R(45374.)
COMPUTE IO1COW=R(45360.)
COMPUTE NLFACT=R(45737.)
 
/* the following lines create additional variables */
 
DO IF (Q5B2_22 NE -4)
COMPUTE ABSPD=Q5B2_22
ELSE IF (R(45577.) NE -4)
COMPUTE ABSPD=R(45577.)
ELSE
COMPUTE ABSPD=R(45393.)
END IF
 
DO IF (Q5B2_65 NE -4)
COMPUTE LKAVL=Q5B2_65
ELSE IF (R(45647.) NE -4)
COMPUTE LKAVL=R(45647.)
ELSE
COMPUTE LKAVL=R(45539.)
END IF
 
DO IF (Q5B2_51 NE -4)
COMPUTE LAYAVL=Q5B2_51
ELSE IF (Q5B_51 NE -4)
COMPUTE LAYAVL=Q5B_51
ELSE
COMPUTE LAYAVL=R(45470.)
END IF
 
DO IF (Q5B2_66 NE -4)
COMPUTE LKAVR=Q5B2_66
ELSE IF (Q5B_66 NE -4)
COMPUTE LKAVR=Q5B_66
ELSE
COMPUTE LKAVR=R(45540.)
END IF
 
DO IF (Q5B2_52 NE -4)
COMPUTE LAYAVR=Q5B2_52
ELSE IF (Q5B_52 NE -4)
COMPUTE LAYAVR=Q5B_52
ELSE
COMPUTE LAYAVR=R(45471.)
END IF
 
DO IF (Q5B2_60 NE -4)
COMPUTE LK=Q5B2_60
ELSE IF (R(45600.) NE -4)
COMPUTE LK=R(45600.)
ELSE
COMPUTE LK=R(45480.)
END IF
 
DO IF (Q5B2_11 NE -4)
COMPUTE DIS1=Q5B2_11
ELSE IF (R(45562.) NE -4)
COMPUTE DIS1=R(45562.)
ELSE
COMPUTE DIS1=R(45375.)
END IF
 
DO IF (Q5B2_12 NE -4)
COMPUTE DIS2=Q5B2_12
ELSE IF (R(45563.) NE -4)
COMPUTE DIS2=R(45563.)
ELSE
COMPUTE DIS2=R(45376.)
END IF
 
/* the following lines create the var DWWNTO */
DO IF (RET1 EQ 1)
COMPUTE DWWNTO=1
 
ELSE IF (Q5B2_78 EQ 1)
COMPUTE DWWNTO=1
ELSE IF (Q5B2_78 EQ 0)
COMPUTE DWWNTO=2
ELSE IF (Q5B2_78 EQ -2)
COMPUTE DWWNTO=-2
ELSE IF (Q5B2_78 EQ -1)
COMPUTE DWWNTO=-1
ELSE IF (Q5B2_78 EQ 3)
COMPUTE DWWNTO=3
ELSE IF (Q5B2_78 EQ 4)
COMPUTE DWWNTO=4
ELSE IF (R(45662.) EQ 1)
COMPUTE DWWNTO=1
ELSE IF (R(45662.) EQ 0)
COMPUTE DWWNTO=2
ELSE IF (R(45662.) EQ -2)
COMPUTE DWWNTO=-2
ELSE IF (R(45662.) EQ -1)
COMPUTE DWWNTO=-1
ELSE IF (R(45662.) EQ 3)
COMPUTE DWWNTO=3
ELSE IF (R(45662.) EQ 4)
COMPUTE DWWNTO=4
ELSE IF (R(45558.) EQ 1)
COMPUTE DWWNTO=1
ELSE IF (R(45558.) EQ 0)
COMPUTE DWWNTO=2
ELSE IF (R(45558.) EQ -2)
COMPUTE DWWNTO=-2
ELSE IF (R(45558.) EQ -1)
COMPUTE DWWNTO=-1
ELSE IF (R(45558.) EQ 3)
COMPUTE DWWNTO=3
ELSE IF (R(45558.) EQ 4)
COMPUTE DWWNTO=4
ELSE
COMPUTE DWWNTO=-3
END IF
 
/* the following lines create the var DIS */
DO IF (Q5_9A4 EQ -4)
COMPUTE DIS=-4
ELSE IF (Q5_9D EQ -1 OR Q5_9E EQ -1 OR Q5_9F EQ -1 OR Q5_9G EQ -1) OR (Q5_9D EQ -2 OR 
                    Q5_9E EQ -2 OR Q5_9F EQ -2 OR Q5_9G EQ -2)
COMPUTE DIS=-2
ELSE IF (Q5_9A4 EQ 1 AND Q5_9D EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9D EQ 0)
COMPUTE DIS=0
ELSE IF (Q5_9A5 EQ 1 AND Q5_9E EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9E EQ 0)
COMPUTE DIS=0
ELSE IF (Q5_9A6 EQ 1 AND Q5_9F EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9F EQ 0)
COMPUTE DIS=0
ELSE IF (Q5_9A7 EQ 1 AND Q5_9G EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9G EQ 0)
COMPUTE DIS=0
ELSE 
COMPUTE DIS=-3
END IF
 
/* the following lines create IO1COW */
DO IF (R(45360.) EQ 1)
COMPUTE IO1COW=8
ELSE
COMPUTE IO1COW=0
END IF
 
/* the following lines create the ESR var approximating MLR */
DO IF ((WK EQ 1 AND (HRCK6 EQ 3 OR HRCK6 EQ -4 OR HRCK6 EQ 99 OR HRCK6 EQ 999)) OR 
                    (BUS1 EQ 1 AND (HRCK7 EQ 2 OR HRCK7 EQ 3 OR HRCK7 EQ 4 OR HRCK7 EQ 5 OR 
                    HRCK7 EQ -4)))
COMPUTE ESR=1
ELSE IF (ABSPD EQ 1 OR ABSPD EQ 0 OR ABSPD EQ -1 OR ABSPD EQ -2)
COMPUTE ESR=2
ELSE IF ((LAYAVL EQ 1 OR LAYAVL EQ -1 OR LAYAVL EQ -2) OR LAYAVR EQ 1)
COMPUTE ESR=3
ELSE IF ((LKAVL EQ 1 OR LKAVL EQ -1 OR LKAVL EQ -2) OR (LKAVR EQ 1 OR LKAVR EQ 2))
COMPUTE ESR=4
ELSE IF ((WK EQ 3 AND AGE GE 50 AND RET1 EQ 1 AND LK EQ 1 AND LKAVL EQ 0 AND 
                    (LKAVR EQ 3 OR LKAVR EQ 4 OR LKAVR EQ -1 OR LKAVR EQ -2)) OR             (RET1 EQ 0 OR 
                    LK EQ 3 OR DWWNTO EQ 3) OR NLFACT EQ 5 OR RETOT EQ 1) 
COMPUTE ESR=5
ELSE IF (DIS1 EQ 1 OR DIS2 EQ 1 OR DIS EQ 1)
COMPUTE ESR=6
ELSE IF (R(45360.) EQ 1)
COMPUTE ESR=8
ELSE
COMPUTE ESR=7
END IF 
 
          ESR(6)=R(15199.);
          ESR(7)=R(18906.);
          ESR(8)=R(22577.);
          ESR(9)=R(24451.);
          ESR(10)=R(28706.);
          ESR(11)=R(30743.);
          ESR(12)=R(34010.);
          ESR(13)=R(36564.);
          ESR(14)=R(40069.);
          ESR(15)=R(44180.);
          ESR(16)=R(50810.);
          ESRC(6)=R(15199.01);
          ESRC(7)=R(18906.01);
          ESRC(8)=R(22577.01);
          ESRC(9)=R(24451.01);
          ESRC(10)=R(28707.);
          ESRC(11)=R(30744.);
          ESRC(12)=R(34011.);
          EARC(13)=R(36565.);
          EARC(14)=R(40070.);
          ESRC(15)=R(44181.);
     ESRC(16)=R(50811.);

 

1996 VARIABLES

/* The programming for the new 1996 ESR variables is done in SPSS */
 
/* the following lines create the var AGE */
COMPUTE AGE=37
 
/* the following lines construct the var HRACT1 */
DO IF (Q5B2_40A EQ -4)
COMPUTE HRACT1=-4
ELSE IF (Q5B2_41A EQ -1 OR Q5B2_41B EQ -1 OR Q5B2_41C EQ -1 OR Q5B2_41D EQ -1 OR 
                    Q5B2_41A EQ -2 OR Q5B2_41B EQ -2 OR Q5B2_41C EQ -2 OR Q5B2_41D EQ -2)
COMPUTE HRACT1=-2
ELSE IF (Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR Q5B2_41D EQ 995)
COMPUTE HRACT1=995
ELSE IF (Q5B2_40B EQ 1 AND Q5B2_41A NE -4)
COMPUTE HRACT1=Q5B2_41A
ELSE IF (Q5B2_40C EQ 1 AND Q5B2_41B NE -4)
COMPUTE HRACT1=Q5B2_41B
ELSE IF (Q5B2_40D EQ 1 AND Q5B2_41C NE -4)
COMPUTE HRACT1=Q5B2_41C
ELSE IF (Q5B2_40E EQ 1 OR Q5B2_40E EQ 0)
COMPUTE HRACT1=Q5B2_41D
ELSE IF (Q5B_40A EQ -4)
COMPUTE HRACT1=-4
ELSE IF (Q5B_41A EQ -1 OR Q5B_41B EQ -1 OR Q5B_41C EQ -1 OR Q5B_41D EQ -1 OR Q5B_41A EQ -2 OR 
                    Q5B_41B EQ -2 OR Q5B_41C EQ -2 OR Q5B_41D EQ -2)
COMPUTE HRACT1=-2
ELSE IF (Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR Q5B_41D EQ 995)
COMPUTE HRACT1=995
ELSE IF (Q5BCK_40B EQ 1 AND Q5B_41A NE -4)
COMPUTE HRACT1=Q5B_41A
ELSE IF (Q5BCK_40C EQ 1 AND Q5B_41B NE -4)
COMPUTE HRACT1=Q5B_41B
ELSE IF (Q5BCK_40D EQ 1 AND Q5B_41C NE -4)
COMPUTE HRACT1=Q5B_41C
ELSE IF (Q5B_40E EQ 1 OR Q5B_40E EQ 0)
COMPUTE HRACT1=Q5B_41D
ELSE IF (R(52404.) EQ -4)
COMPUTE HRACT1=-4
ELSE IF (Q5_41A EQ -1 OR Q5_41B EQ -1 OR Q5_41C EQ -1 OR Q5_41D EQ -1 OR Q5_41A EQ -2 OR 
                    Q5_41B EQ -2 OR Q5_41C EQ -2 OR Q5_41D EQ -2)
COMPUTE HRACT1=-2
ELSE IF (Q5_41A EQ 995 OR Q5_41B EQ 995 OR Q5_41C EQ 995 OR Q5_41D EQ 995)
COMPUTE HRACT1=995
ELSE IF (Q5_40B EQ 1 AND Q5_41A NE -4)
COMPUTE HRACT1= Q5_41A
ELSE IF (Q5_40C EQ 1 AND Q5_41B NE -4)
COMPUTE HRACT1= Q5_41B
ELSE IF (Q5_40D EQ 1 AND Q5_41C NE -4)
COMPUTE HRACT1= Q5_41C
ELSE IF (Q5_40E EQ 1 OR Q5_4OE EQ 0)
COMPUTE HRACT1= Q5_41D
ELSE
COMPUTE HRACT1=-3
END IF
 
/* the following lines construct the var HRACT2 */
DO IF (Q5B2_42 EQ -4 OR Q5B2_42 EQ 0)
COMPUTE HRACT2=-4
ELSE IF (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2)
COMPUTE HRACT2=-2
ELSE IF (Q5B2_43A EQ 995 OR Q5B2_43B EQ 995)
COMPUTE HRACT2=995
ELSE IF (Q5B2_43 EQ 1)
COMPUTE HRACT2=Q5B2_43A
ELSE IF (Q5B2_42 EQ 1 AND Q5B2_43 EQ 0)
COMPUTE HRACT2=Q5B2_43B
ELSE IF (Q5B_42 EQ -4 OR Q5B_42 EQ 0)
COMPUTE HRACT2=-4
ELSE IF (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2)
COMPUTE HRACT2=-2
ELSE IF (Q5B_43A EQ 995 OR Q5B_43B EQ 995)
COMPUTE HRACT2=995
ELSE IF (Q5B_43 EQ 1)
COMPUTE HRACT2=Q5B_43A
ELSE IF (Q5B_42 EQ 1 AND Q5B_43 EQ 0)
COMPUTE HRACT2=Q5B_43B
ELSE IF (Q5_42 EQ -4 OR Q5_42 EQ 0)
COMPUTE HRACT2=-4
ELSE IF (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2)
COMPUTE HRACT2=-2
ELSE IF (Q5_43A EQ 995 OR Q5_43B EQ 995)
COMPUTE HRACT2=995
ELSE IF (Q5_43 EQ 1)
COMPUTE HRACT2= Q5_43A
ELSE IF (Q5_42 EQ 1 AND Q5_43 EQ 0)
COMPUTE HRACT2= Q5_43B
ELSE 
COMPUTE HRACT2=-3
END IF
 
/* the following lines create the var HRACTT */
DO IF (Q5B2_40A EQ -4)
COMPUTE HRACTT=-4
ELSE IF ((Q5B2_41A EQ -1 OR Q5B2_41B EQ -1 OR Q5B2_41C EQ -1 OR Q5B2_41D EQ -1 OR 
                    Q5B2_41A EQ -2 OR Q5B2_41B EQ -2 OR Q5B2_41C EQ -2 OR Q5B2_41D EQ -2) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2))
COMPUTE HRACTT=-2
ELSE IF ((Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR Q5B2_41D EQ 995) AND 
                    (Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B2_41A EQ -1 OR Q5B2_41B EQ -1 OR Q5B2_41C EQ -1 OR Q5B2_41D EQ -1 OR 
                    Q5B2_41A EQ -2 OR Q5B2_41B EQ -2 OR Q5B2_41C EQ -2 OR Q5B2_41D EQ -2) AND 
                    (Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR Q5B2_41D EQ 995 OR 
                    Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR Q5B2_41D EQ 995) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2))
COMPUTE HRACTT=995
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND Q5B2_41A NE 995) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR 
                    Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41A
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND Q5B2_41B NE 995) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR 
                    Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41B
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND Q5B2_41C NE 995) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR 
                    Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41C
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND Q5B2_41D NE 995) AND 
                    (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR 
                    Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41D
ELSE IF ((Q5B2_43A NE -4 AND Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND Q5B2_43A NE 995) AND 
                    (Q5B2_41A EQ -1 OR Q5B2_41A EQ -2 OR Q5B2_41A EQ 995 OR Q5B2_41B EQ -1 OR 
                    Q5B2_41B EQ -2 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ -1 OR Q5B2_41C EQ -2 OR 
                    Q5B2_41C EQ 995 OR Q5B2_41D EQ -1 OR Q5B2_41D EQ -2 OR Q5B2_41D EQ 995))
COMPUTE HRACTT=Q5B2_43A
ELSE IF ((Q5B2_43B NE -4 AND Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND Q5B2_43B NE 995) AND 
                    (Q5B2_41A EQ -1 OR Q5B2_41A EQ -2 OR Q5B2_41A EQ 995 OR Q5B2_41B EQ -1 OR 
                    Q5B2_41B EQ -2 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ -1 OR Q5B2_41C EQ -2 OR 
                    Q5B2_41C EQ 995 OR Q5B2_41D EQ -1 OR Q5B2_41D EQ -2 OR Q5B2_41D EQ 995))
COMPUTE HRACTT=Q5B2_43B
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND Q5B2_41A NE 995) AND 
                    (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41A+Q5B2_43A
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND Q5B2_41A NE 995) AND 
                    (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41A+Q5B2_43B
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND Q5B2_41B NE 995) AND 
                    (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41B+Q5B2_43A
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND Q5B2_41B NE 995) AND 
                    (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41B+Q5B2_43B
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND Q5B2_41C NE 995) AND 
                    (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41C+Q5B2_43A
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND Q5B2_41C NE 995) AND 
                    (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41C+Q5B2_43B
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND Q5B2_41D NE 995) AND 
                    (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41D+Q5B2_43A
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND Q5B2_41D NE 995) AND 
                    (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41D+Q5B2_43B
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND Q5B2_41A NE 995) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41A
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND Q5B2_41B NE 995) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41B
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND Q5B2_41C NE 995) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41C
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND Q5B2_41D NE 995) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41D
ELSE IF ((Q5B2_41A EQ -1 OR Q5B2_41A EQ -2 OR Q5B2_41B EQ -1 OR Q5B2_41B EQ -2 OR 
                    Q5B2_41C EQ -1 OR Q5B2_41C EQ -2 OR Q5B2_41D EQ -1 OR Q5B2_41D EQ -2) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=-2
ELSE IF ((Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR Q5B2_41D EQ 995) AND 
                    Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=995
ELSE IF (Q5B_40A EQ -4)
COMPUTE HRACTT=-4
ELSE IF ((Q5B_41A EQ -1 OR Q5B_41B EQ -1 OR Q5B_41C EQ -1 OR Q5B_41D EQ -1 OR Q5B_41A EQ -2 OR 
                    Q5B_41B EQ -2 OR Q5B_41C EQ -2 OR Q5B_41D EQ -2) AND (Q5B_43A EQ -1 OR 
                    Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2))
COMPUTE HRACTT=-2
ELSE IF ((Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR Q5B_41D EQ 995) AND 
                    (Q5B_43A EQ 995 OR Q5B_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B_41A EQ -1 OR Q5B_41B EQ -1 OR Q5B_41C EQ -1 OR Q5B_41D EQ -1 OR Q5B_41A EQ -2 OR 
                    Q5B_41B EQ -2 OR Q5B_41C EQ -2 OR Q5B_41D EQ -2) AND (Q5B_43A EQ 995 OR 
                    Q5B_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR Q5B_41D EQ 995 OR 
                    Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR Q5B_41D EQ 995) AND 
                    (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2))
COMPUTE HRACTT=995
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND Q5B_41A NE 995) AND 
                    (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR 
                    Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41A
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND Q5B_41B NE 995) AND 
                    (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR 
                    Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41B
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND Q5B_41C NE 995) AND 
                    (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR
                    Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41C
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND Q5B_41D NE 995) AND 
                    (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR 
                    Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41D
ELSE IF ((Q5B_43A NE -4 AND Q5B_43A NE -1 AND Q5B_43A NE -2 AND Q5B_43A NE 995) AND 
                    (Q5B_41A EQ -1 OR Q5B_41A EQ -2 OR Q5B_41A EQ 995 OR Q5B_41B EQ -1 OR Q5B_41B EQ -2 OR 
                    Q5B_41B EQ 995 OR Q5B_41C EQ -1 OR Q5B_41C EQ -2 OR Q5B_41C EQ 995 OR 
                    Q5B_41D EQ -1 OR Q5B_41D EQ -2 OR Q5B_41D EQ 995))
COMPUTE HRACTT=Q5B_43A
ELSE IF ((Q5B_43B NE -4 AND Q5B_43B NE -1 AND Q5B_43B NE -2 AND Q5B_43B NE 995) AND 
                    (Q5B_41A EQ -1 OR Q5B_41A EQ -2 OR Q5B_41A EQ 995 OR Q5B_41B EQ -1 OR Q5B_41B EQ -2 OR 
                    Q5B_41B EQ 995 OR Q5B_41C EQ -1 OR Q5B_41C EQ -2 OR Q5B_41C EQ 995 OR 
                    Q5B_41D EQ -1 OR Q5B_41D EQ -2 OR Q5B_41D EQ 995))
COMPUTE HRACTT=Q5B_43B
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND Q5B_41A NE 995) AND 
                    (Q5B_43A NE -1 AND Q5B_43A NE -2 AND Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41A+Q5B_43A
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND Q5B_41A NE 995) AND 
                    (Q5B_43B NE -1 AND Q5B_43B NE -2 AND Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41A+Q5B_43B
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND Q5B_41B NE 995) AND 
                    (Q5B_43A NE -1 AND Q5B_43A NE -2 AND Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41B+Q5B_43A
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND Q5B_41B NE 995) AND 
                    (Q5B_43B NE -1 AND Q5B_43B NE -2 AND Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41B+Q5B_43B
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND Q5B_41C NE 995) AND 
                    (Q5B_43A NE -1 AND Q5B_43A NE -2 AND Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41C+Q5B_43A
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND Q5B_41C NE 995) AND 
                    (Q5B_43B NE -1 AND Q5B_43B NE -2 AND Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41C+Q5B_43B
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND Q5B_41D NE 995) AND 
                    (Q5B_43A NE -1 AND Q5B_43A NE -2 AND Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41D+Q5B_43A
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND Q5B_41D NE 995) AND 
                    (Q5B_43B NE -1 AND Q5B_43B NE -2 AND Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41D+Q5B_43B
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND Q5B_41A NE 995) AND 
                    Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41A
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND Q5B_41B NE 995) AND 
                    Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41B
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND Q5B_41C NE 995) AND 
                    Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41C
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND Q5B_41D NE 995) AND 
                    Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41D
ELSE IF ((Q5B_41A EQ -1 OR Q5B_41A EQ -2 OR Q5B_41B EQ -1 OR Q5B_41B EQ -2 OR Q5B_41C EQ -1 OR
                    Q5B_41C EQ -2 OR Q5B_41D EQ -1 OR Q5B_41D EQ -2) AND Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=-2
ELSE IF ((Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR Q5B_41D EQ 995) AND 
                    Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=995
ELSE IF (R(52404.) EQ -4)
COMPUTE HRACTT=-4
ELSE IF ((Q5_41A EQ -1 OR Q5_41B EQ -1 OR Q5_41C EQ -1 OR Q5_41D EQ -1 OR Q5_41A EQ -2 OR 
                    Q5_41B EQ -2 OR Q5_41C EQ -2 OR Q5_41D EQ -2) AND (Q5_43A EQ -1 OR 
                    Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2))
COMPUTE HRACTT=-2
ELSE IF ((Q5_41A EQ 995 OR Q5_41B EQ 995 OR Q5_41C EQ 995 OR Q5_41D EQ 995) AND 
                    (Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5_41A EQ -1 OR Q5_41B EQ -1 OR Q5_41C EQ -1 OR Q5_41D EQ -1 OR Q5_41A EQ -2 OR 
                    Q5_41B EQ -2 OR Q5_41C EQ -2 OR Q5_41D EQ -2) AND (Q5_43A EQ 995 OR 
                    Q5_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5_41A EQ 995 OR Q5_41B EQ 995 OR Q5_41C EQ 995 OR Q5_41D EQ 995 OR 
                    Q5_41A EQ 995 OR Q5_41B EQ 995 OR Q5_41C EQ 995 OR Q5_41D EQ 995) AND 
                    (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2))
COMPUTE HRACTT=995
ELSE IF ((Q5_41A NE -4 AND Q5_41A NE -1 AND Q5_41A NE -2 AND Q5_41A NE 995) AND 
                    (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2 OR 
                    Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT= Q5_41A
ELSE IF ((Q5_41B NE -4 AND Q5_41B NE -1 AND Q5_41B NE -2 AND Q5_41B NE 995) AND 
                    (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2 OR 
                    Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT= Q5_41B
ELSE IF ((Q5_41C NE -4 AND Q5_41C NE -1 AND Q5_41C NE -2 AND Q5_41C NE 995) AND 
                    (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2 OR 
                    Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT= Q5_41C
ELSE IF ((Q5_41D NE -4 AND Q5_41D NE -1 AND Q5_41D NE -2 AND Q5_41D NE 995) AND 
                    (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2 OR 
                    Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT= Q5_41D
ELSE IF ((Q5_43A NE -4 AND Q5_43A NE -1 AND Q5_43A NE -2 AND Q5_43A NE 995) AND 
                    (Q5_41A EQ -1 OR Q5_41A EQ -2 OR Q5_41A EQ 995 OR Q5_41B EQ -1 OR 
                    Q5_41B EQ -2 OR Q5_41B EQ 995 OR Q5_41C EQ -1 OR Q5_41C EQ -2 OR 
                    Q5_41C EQ 995 OR Q5_41D EQ -1 OR Q5_41D EQ -2 OR Q5_41D EQ 995))
COMPUTE HRACTT= Q5_43A
ELSE IF ((Q5_43B NE -4 AND Q5_43B NE -1 AND Q5_43B NE -2 AND Q5_43B NE 995) AND 
                    Q5_41A EQ -1 OR Q5_41A EQ -2 OR Q5_41A EQ 995 OR Q5_41B EQ -1 OR Q5_41B EQ -2 OR 
                    Q5_41B EQ 995 OR Q5_41C EQ -1 OR Q5_41C EQ -2 OR Q5_41C EQ 995 OR 
                    Q5_41D EQ -1 OR Q5_41D EQ -2 OR Q5_41D EQ 995))
COMPUTE HRACTT= Q5_43B
ELSE IF ((Q5_41A NE -4 AND Q5_41A NE -1 AND Q5_41A NE -2 AND Q5_41A NE 995) AND 
                    (Q5_43A NE -1 AND Q5_43A NE -2 AND Q5_43A NE 995 AND Q5_43A NE -4)) 
COMPUTE HRACTT= Q5_41A+Q5_43A
ELSE IF ((Q5_41A NE -4 AND Q5_41A NE -1 AND Q5_41A NE -2 AND Q5_41A NE 995) AND 
                    (Q5_43B NE -1 AND Q5_43B NE -2 AND Q5_43B NE 995 AND Q5_43B NE -4)) 
COMPUTE HRACTT= Q5_41A+Q5_43B
ELSE IF ((Q5_41B NE -4 AND Q5_41B NE -1 AND Q5_41B NE -2 AND Q5_41B NE 995) AND 
                    (Q5_43A NE -1 AND Q5_43A NE -2 AND Q5_43A NE 995 AND Q5_43A NE -4)) 
COMPUTE HRACTT= Q5_41B+ Q5_43A
ELSE IF ((Q5_41B NE -4 AND Q5_41B NE -1 AND Q5_41B NE -2 AND Q5_41B NE 995) AND 
                    (Q5_43B NE -1 AND Q5_43B NE -2 AND Q5_43B NE 995 AND Q5_43B NE -4)) 
COMPUTE HRACTT= Q5_41B+ Q5_43B
ELSE IF ((Q5_41C NE -4 AND Q5_41C NE -1 AND Q5_41C NE -2 AND Q5_41C NE 995) AND 
                    (Q5_43A NE -1 AND Q5_43A NE -2 AND Q5_43A NE 995 AND Q5_43A NE -4)) 
COMPUTE HRACTT= Q5_41C+ Q5_43A
ELSE IF ((Q5_41C NE -4 AND Q5_41C NE -1 AND Q5_41C NE -2 AND Q5_41C NE 995) AND 
                    (Q5_43B NE -1 AND Q5_43B NE -2 AND Q5_43B NE 995 AND Q5_43B NE -4)) 
COMPUTE HRACTT= Q5_41C Q5_43B
ELSE IF ((Q5_41D NE -4 AND Q5_41D NE -1 AND Q5_41D NE -2 AND Q5_41D NE 995) AND 
                    (Q5_43A NE -1 AND Q5_43A NE -2 AND Q5_43A NE 995 AND Q5_43A NE -4)) 
COMPUTE HRACTT= Q5_41D+ Q5_43A
ELSE IF ((Q5_41D NE -4 AND Q5_41D NE -1 AND Q5_41D NE -2 AND Q5_41D NE 995) AND 
                    (Q5_43B NE -1 AND Q5_43B NE -2 AND Q5_43B NE 995 AND Q5_43B NE -4)) 
COMPUTE HRACTT= Q5_41D+ Q5_43B
ELSE IF ((Q5_41A NE -4 AND Q5_41A NE -1 AND Q5_41A NE -2 AND Q5_41A NE 995) AND 
                    Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT= Q5_41A
ELSE IF ((Q5_41B NE -4 AND Q5_41B NE -1 AND Q5_41B NE -2 AND Q5_41B NE 995) AND 
                    Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT= Q5_41B
ELSE IF ((Q5_41C NE -4 AND Q5_41C NE -1 AND Q5_41C NE -2 AND Q5_41C NE 995) AND 
                    Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT= Q5_41C
ELSE IF ((Q5_41D NE -4 AND Q5_41D NE -1 AND Q5_41D NE -2 AND Q5_41D NE 995) AND 
                    Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT= Q5_41D
ELSE IF ((Q5_41A EQ -1 OR Q5_41A EQ -2 OR Q5_41B EQ -1 OR Q5_41B EQ -2 OR Q5_41C EQ -1 OR
                    Q5_41C EQ -2 OR Q5_41D EQ -1 OR Q5_41D EQ -2) AND Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT=-2
ELSE IF ((Q5_41A EQ 995 OR Q5_41B EQ 995 OR Q5_41C EQ 995 OR Q5_41D EQ 995) AND 
                    Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT=995
ELSE 
COMPUTE HRACTT=-3
END IF
 
/* the following lines creates the var BUS2 */
DO IF (R(52322.) EQ -4)
COMPUTE BUS2=-4
ELSE IF (R(52322.) EQ -1)
COMPUTE BUS2=-1
ELSE IF (R(52322.) EQ -2)
COMPUTE BUS2=-2
ELSE IF (R(52323.) EQ -1 OR R(52324.) EQ -1)
COMPUTE BUS2=-1
ELSE IF (R(52323.) EQ -2 OR R(52324.) EQ -2)
COMPUTE BUS2=-2
ELSE IF (R(52323.) EQ 1 OR R(52324.) EQ 1)
COMPUTE BUS2=1
ELSE IF (R(52324.) EQ 0)
COMPUTE BUS2=2  /* this should normally be 0 */
ELSE 
COMPUTE BUS2=-3
END IF
 
/* the following lines create the var HRUSL1 */
DO IF (Q5BCK2_25 EQ -4)
COMPUTE HRUSL1=-4
ELSE IF (Q5BCK2_26A EQ -1 OR Q5BCK2_26C EQ -1 OR Q5BCK2_26A EQ -2 OR Q5BCK2_26C EQ -2)
COMPUTE HRUSL1=-2
ELSE IF (Q5BCK2_26A EQ 995 OR Q5BCK2_26C EQ 995)
COMPUTE HRUSL1=995
ELSE IF (Q5BCK2_26A EQ 1)
COMPUTE HRUSL1=Q5B2_26B
ELSE IF (Q5BCK2_26C EQ 1)
COMPUTE HRUSL1=Q5B2_26D
ELSE IF (R(52486.) EQ -4)
COMPUTE HRUSL1=-4
ELSE IF (Q5B_26A EQ -1 OR R(52487.) EQ -1 OR Q5B_26A EQ -2 OR R(52487.) EQ -2)
COMPUTE HRUSL1=-2
ELSE IF (Q5B_26A EQ 995 OR R(52487.) EQ 995)
COMPUTE HRUSL1=995
ELSE IF (Q5B_26A EQ 1)
COMPUTE HRUSL1=Q5B_26B
ELSE IF (R(52487.) EQ 1)
COMPUTE HRUSL1=R(52488.)
ELSE IF (R(52360.) EQ -4)
COMPUTE HRUSL1=-4
ELSE IF (R(52361.) EQ -1 OR R(52363.) EQ -1 OR R(52361.) EQ -2 OR R(52363.) EQ -2)
COMPUTE HRUSL1=-2
ELSE IF (R(52361.) EQ 995 OR R(52363.) EQ 995)
COMPUTE HRUSL1=995
ELSE IF (R(52361.) EQ 1)
COMPUTE HRUSL1=R(52362.)
ELSE IF (R(52363.) EQ 1)
COMPUTE HRUSL1=R(52364.)
ELSE 
COMPUTE HRUSL1=-3
END IF
 
/* the following lines create the var HRUSL2 */
DO IF (Q5B2_28A EQ -4)
COMPUTE HRUSL2=-4
ELSE IF (Q5B2_28B EQ -1 OR Q5B2_28D EQ -1 OR Q5B2_28B EQ -2 OR Q5B2_28D EQ -2)
COMPUTE HRUSL2=-2
ELSE IF (Q5B2_28B EQ 995 OR Q5B2_28D EQ 995)
COMPUTE HRUSL2=995
ELSE IF (Q5B2_28B EQ 1)
COMPUTE HRUSL2=Q5B2_28C
ELSE IF (Q5B2_28D EQ 1)
COMPUTE HRUSL2=Q5B2_28E
ELSE IF (Q5B_28A EQ -4)
COMPUTE HRUSL2=-4
ELSE IF (Q5B_28B EQ -1 OR Q5B_28D EQ -1 OR Q5B_28B EQ -2 OR Q5B_28D EQ -2)
COMPUTE HRUSL2=-2
ELSE IF (Q5B_28B EQ 995 OR Q5B_28D EQ 995)
COMPUTE HRUSL2=995
ELSE IF (Q5B_28B EQ 1)
COMPUTE HRUSL2=Q5B_28C
ELSE IF (Q5B_28D EQ 1)
COMPUTE HRUSL2=Q5B_28E
ELSE IF (R(52366.) EQ -4)
COMPUTE HRUSL2=-4
ELSE IF (R(52367.) EQ -1 OR R(52369.) EQ -1 OR R(52367.) EQ -2 OR R(52369.) EQ -2)
COMPUTE HRUSL2=-2
ELSE IF (R(52367.) EQ 995 OR R(52369.) EQ 995)
COMPUTE HRUSL2=995
ELSE IF (R(52367.) EQ 1)
COMPUTE HRUSL2=Q5_28C
ELSE IF (R(52369.) EQ 1)
COMPUTE HRUSL2=Q5_28E
ELSE 
COMPUTE HRUSL2=-3
END IF 
 
/* the following lines create the var HRUSLT */
DO IF (Q5BCK2_25 EQ -4)
COMPUTE HRUSLT=-4
ELSE IF ((Q5BCK2_26A EQ -1 OR Q5BCK2_26C EQ -1 OR Q5BCK2_26A EQ -2 OR Q5BCK2_26C EQ -2) AND 
                    (Q5B2_28B EQ -1 OR Q5B2_28D EQ -1 OR Q5B2_28B EQ -2 OR Q5B2_28D EQ -2))
COMPUTE HRUSLT=-2
ELSE IF ((Q5BCK2_26A EQ 995 OR Q5BCK2_26C EQ 995) AND (Q5B2_28B EQ 995 OR Q5B2_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5BCK2_26A EQ -1 OR Q5BCK2_26C EQ -1 OR Q5BCK2_26A EQ -2 OR Q5BCK2_26C EQ -2) AND 
                    (Q5B2_28B EQ 995 OR Q5B2_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5BCK2_26A EQ 995 OR Q5BCK2_26C EQ 995) AND (Q5B2_28B EQ -1 OR Q5B2_28D EQ -1 OR 
                    Q5B2_28B EQ -2 OR Q5B2_28D EQ -2))
COMPUTE HRUSLT=995
ELSE IF ((Q5BCK2_26A EQ 995 OR Q5BCK2_26C EQ 995) AND Q5B2_27 NE 1)
COMPUTE HRUSLT=995
ELSE IF ((Q5BCK2_26A EQ -1 OR Q5BCK2_26C EQ -1 OR Q5BCK2_26A EQ -2 OR Q5BCK2_26C EQ -2) AND Q5B2_27 NE 1)
COMPUTE HRUSLT=-2
ELSE IF (Q5BCK2_26A EQ 1 AND (Q5B2_28B EQ -1 OR Q5B2_28B EQ -2 OR Q5B2_28B EQ 995 OR 
                    Q5B2_28D EQ -1 OR Q5B2_28D EQ -2 OR Q5B2_28D EQ 995))
COMPUTE HRUSLT=Q5B2_26B
ELSE IF (Q5BCK2_26C EQ 1 AND (Q5B2_28B EQ -1 OR Q5B2_28B EQ -2 OR Q5B2_28B EQ 995 OR 
                    Q5B2_28D EQ -1 OR Q5B2_28D EQ -2 OR Q5B2_28D EQ 995))
COMPUTE HRUSLT=Q5B2_26D
ELSE IF (Q5B2_28B EQ 1 AND (Q5BCK2_26A EQ -1 OR Q5BCK2_26A EQ -2 OR Q5BCK2_26A EQ 995 OR 
                    Q5BCK2_26C EQ -1 OR Q5BCK2_26C EQ -2 OR Q5BCK2_26C EQ 995))
COMPUTE HRUSLT=Q5B2_28C
ELSE IF (Q5B2_28D EQ 1 AND (Q5BCK2_26A EQ -1 OR Q5BCK2_26A EQ -2 OR Q5BCK2_26A EQ 995 OR 
                    Q5BCK2_26C EQ -1 OR Q5BCK2_26C EQ -2 OR Q5BCK2_26C EQ 995))
COMPUTE HRUSLT=Q5B2_28E
ELSE IF (Q5BCK2_26A EQ 1 AND Q5B2_27 NE 1)
COMPUTE HRUSLT=Q5B2_26B
ELSE IF (Q5BCK2_26C EQ 1 AND Q5B2_27 NE 1)
COMPUTE HRUSLT=Q5B2_26D
ELSE IF (Q5BCK2_26A EQ 1 AND Q5B2_28B EQ 1)
COMPUTE HRUSLT=Q5B2_26B+Q5B2_28C
ELSE IF (Q5BCK2_26A EQ 1 AND Q5B2_28D EQ 1)
COMPUTE HRUSLT=Q5B2_26B+Q5B2_28E
ELSE IF (Q5BCK2_26C EQ 1 AND Q5B2_28B EQ 1)
COMPUTE HRUSLT=Q5B2_26D+Q5B2_28C
ELSE IF (Q5BCK2_26C EQ 1 AND Q5B2_28D EQ 1)
COMPUTE HRUSLT= Q5BCK2_26C+Q5B2_28E
ELSE IF (R(52486.) EQ -4)
COMPUTE HRUSLT=-4
ELSE IF ((Q5B_26A EQ -1 OR R(52487.) EQ -1 OR Q5B_26A EQ -2 OR R(52487.) EQ -2) AND 
                    (Q5B_28B EQ -1 OR Q5B_28D EQ -1 OR Q5B_28B EQ -2 OR Q5B_28D EQ -2))
COMPUTE HRUSLT=-2
ELSE IF ((Q5B_26A EQ 995 OR R(52487.) EQ 995) AND (Q5B_28B EQ 995 OR Q5B_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ -1 OR R(52487.) EQ -1 OR Q5B_26A EQ -2 OR R(52489.) EQ -2) AND 
                    (Q5B_28B EQ 995 OR Q5B_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ 995 OR R(52487.) EQ 995) AND (Q5B_28B EQ -1 OR Q5B_28D EQ -1 OR 
                    Q5B_28B EQ -2 OR Q5B_28D EQ -2))
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ 995 OR R(52487.) EQ 995) AND R(52489.) NE 1)
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ -1 OR R(52487.) EQ -1 OR Q5B_26A EQ -2 OR R(52487.) EQ -2) AND R(52489.) NE 1)
COMPUTE HRUSLT=-2
ELSE IF (Q5B_26A EQ 1 AND (Q5B_28B EQ -1 OR Q5B_28B EQ -2 OR Q5B_28B EQ 995 OR 
                    Q5B_28D EQ -1 OR Q5B_28D EQ -2 OR Q5B_28D EQ 995))
COMPUTE HRUSLT=Q5B_26B
ELSE IF (R(52487.) EQ 1 AND (Q5B_28B EQ -1 OR Q5B_28B EQ -2 OR Q5B_28B EQ 995 OR 
                    Q5B_28D EQ -1 OR Q5B_28D EQ -2 OR Q5B_28D EQ 995))
COMPUTE HRUSLT=R(52488.)
ELSE IF (Q5B_28B EQ 1 AND (Q5B_26A EQ -1 OR Q5B_26A EQ -2 OR Q5B_26A EQ 995 OR 
                    R(52487.) EQ -1 OR R(52487.) EQ -2 OR R(52487.) EQ 995))
COMPUTE HRUSLT=Q5B_28C
ELSE IF (Q5B_28D EQ 1 AND (Q5B_26A EQ -1 OR Q5B_26A EQ -2 OR Q5B_26A EQ 995 OR 
                    R(52487.) EQ -1 OR R(52487.) EQ -2 OR R(52487.) EQ 995))
COMPUTE HRUSLT=Q5B_28E
ELSE IF (Q5B_26A EQ 1 AND R(52489.) NE 1)
COMPUTE HRUSLT=Q5B_26B
ELSE IF (R(52487.) EQ 1 AND R(52489.) NE 1)
COMPUTE HRUSLT=R(52488.)
ELSE IF (Q5B_26A EQ 1 AND Q5B_28B EQ 1)
COMPUTE HRUSLT=Q5B_26B+Q5B_28C
ELSE IF (Q5B_26A EQ 1 AND Q5B_28D EQ 1)
COMPUTE HRUSLT=Q5B_26B+Q5B_28E
ELSE IF (R(52487.) EQ 1 AND Q5B_28B EQ 1)
COMPUTE HRUSLT=R(52488.)+Q5B_28C
ELSE IF (R(52487.) EQ 1 AND Q5B_28D EQ 1)
COMPUTE HRUSLT=R(52487.)+Q5B_28E
ELSE IF (R(52360.) EQ -4)
COMPUTE HRUSLT=-4
ELSE IF ((R(52361.) EQ -1 OR R(52363.) EQ -1 OR R(52361.) EQ -2 OR R(52363.) EQ -2) AND 
                    (R(52367.) EQ -1 OR R(52369.) EQ -1 OR R(52367.) EQ -2 OR R(52369.) EQ -2))
COMPUTE HRUSLT=-2
ELSE IF ((R(52361.) EQ 995 OR R(52363.) EQ 995) AND (R(52367.) EQ 995 OR R(52369.) EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((R(52361.) EQ -1 OR R(52363.) EQ -1 OR R(52361.) EQ -2 OR R(52363.) EQ -2) AND 
                    (R(52367.) EQ 995 OR R(52369.) EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((R(52361.) EQ 995 OR R(52363.) EQ 995) AND (R(52367.) EQ -1 OR R(52369.) EQ -1 OR 
                    R(52367.) EQ -2 OR R(52369.) EQ -2))
COMPUTE HRUSLT=995
ELSE IF ((R(52361.) EQ 995 OR R(52363.) EQ 995) AND R(52365.) NE 1)
COMPUTE HRUSLT=995
ELSE IF ((R(52361.) EQ -1 OR R(52363.) EQ -1 OR R(52361.) EQ -2 OR R(52363.) EQ -2) AND R(52365.) NE 1)
COMPUTE HRUSLT=-2
ELSE IF (R(52361.) EQ 1 AND (R(52367.) EQ -1 OR R(52367.) EQ -2 OR R(52367.) EQ 995 OR 
                    R(52369.) EQ -1 OR R(52369.) EQ -2 OR R(52369.) EQ 995))
COMPUTE HRUSLT=R(52362.)
ELSE IF (R(52363.) EQ 1 AND (R(52367.) EQ -1 OR R(52367.) EQ -2 OR R(52367.) EQ 995 OR 
                    R(52369.) EQ -1 OR R(52369.) EQ -2 OR R(52369.) EQ 995))
COMPUTE HRUSLT=R(52364.)
ELSE IF (R(52367.) EQ 1 AND (R(52361.) EQ -1 OR R(52361.) EQ -2 OR R(52361.) EQ 995 OR 
                    R(52363.) EQ -1 OR R(52363.) EQ -2 OR R(52363.) EQ 995))
COMPUTE HRUSLT=R(52368.)
ELSE IF (R(52369.) EQ 1 AND (R(52361.) EQ -1 OR R(52361.) EQ -2 OR R(52361.) EQ 995 OR 
                    R(52363.) EQ -1 OR R(52363.) EQ -2 OR R(52363.) EQ 995))
COMPUTE HRUSLT=R(52370.)
ELSE IF (R(52361.) EQ 1 AND R(52365.) NE 1)
COMPUTE HRUSLT=R(52362.)
ELSE IF (R(52363.) EQ 1 AND R(52365.) NE 1)
COMPUTE HRUSLT=R(52364.)
ELSE IF (R(52361.) EQ 1 AND R(52367.) EQ 1)
COMPUTE HRUSLT=R(52362.)+R(52368.)
ELSE IF (R(52361.) EQ 1 AND R(52369.) EQ 1)
COMPUTE HRUSLT=R(52362.)+R(52370.)
ELSE IF (R(52363.) EQ 1 AND R(52367.) EQ 1)
COMPUTE HRUSLT=R(52364.)+R(52368.)
ELSE IF (R(52363.) EQ 1 AND R(52369.) EQ 1)
COMPUTE HRUSLT=R(52363.)+R(52370.)
ELSE 
COMPUTE HRUSLT=-3
END IF
 
/* the following lines create the var HRFTPT */
DO IF (Q5B2_30C EQ -4)
COMPUTE HRFTPT=-4
ELSE IF (Q5B2_30F EQ -1 OR Q5B2_30G EQ -1 OR Q5B2_30H EQ -1 OR Q5B2_30I EQ -1)
COMPUTE HRFTPT=-1
ELSE IF (Q5B2_30F EQ -2 OR Q5B2_30G EQ -2 OR Q5B2_30H EQ -2 OR Q5B2_30I EQ -2)
COMPUTE HRFTPT=-2
ELSE IF (Q5B2_30F NE -4)
COMPUTE HRFTPT=Q5B2_30F
ELSE IF (Q5B2_30G NE -4)
COMPUTE HRFTPT=Q5B2_30G
ELSE IF (Q5B2_30H NE -4)
COMPUTE HRFTPT=Q5B2_30H
ELSE IF (Q5B2_30I NE -4)
COMPUTE HRFTPT=Q5B2_30I
ELSE IF (Q5B_30C EQ -4)
COMPUTE HRFTPT=-4
ELSE IF (Q5B_30F EQ -1 OR Q5B_30G EQ -1 OR Q5B_30H EQ -1 OR Q5B_30I EQ -1)
COMPUTE HRFTPT=-1
ELSE IF (Q5B_30F EQ -2 OR Q5B_30G EQ -2 OR Q5B_30H EQ -2 OR Q5B_30I EQ -2)
COMPUTE HRFTPT=-2
ELSE IF (Q5B_30F NE -4)
COMPUTE HRFTPT=Q5B_30F
ELSE IF (Q5B_30G NE -4)
COMPUTE HRFTPT=Q5B_30G
ELSE IF (Q5B_30H NE -4)
COMPUTE HRFTPT=Q5B_30H
ELSE IF (Q5B_30I NE -4)
COMPUTE HRFTPT=Q5B_30I
ELSE IF (R(52381.) EQ -4)
COMPUTE HRFTPT=-4
ELSE IF (Q5_30F EQ -1 OR R(52384.) EQ -1 OR R(52385.) EQ -1 OR R(52386.) EQ -1)
COMPUTE HRFTPT=-1
ELSE IF (Q5_30F EQ -2 OR R(52384.) EQ -2 OR R(52385.) EQ -2 OR R(52386.) EQ -2)
COMPUTE HRFTPT=-2
ELSE IF (Q5_30F NE -4)
COMPUTE HRFTPT=Q5_30F
ELSE IF (R(52384.) NE -4)
COMPUTE HRFTPT=R(52384.)
ELSE IF (R(52385.) NE -4)
COMPUTE HRFTPT=R(52385.)
ELSE IF (R(52386.) NE -4)
COMPUTE HRFTPT=R(52386.)
ELSE
COMPUTE HRFTPT=-3
END IF 
 
/* the following lines create the var HRWANT */
DO IF (Q5B2_33 NE -4)
COMPUTE HRWANT=Q5B2_33
ELSE IF (Q5B_33 NE -4)
COMPUTE HRWANT=Q5B_33
ELSE 
COMPUTE HRWANT=R(52397.)
END IF
 
/* the following lines create the var HRRSN1 */
DO IF (Q5B2_34 NE -4)
COMPUTE HRRSN1=Q5B2_34
ELSE IF (Q5B_34 NE -4)
COMPUTE HRRSN1=Q5B_34
ELSE
COMPUTE HRRSN1=R(52398.)
END IF
 
/* the following lines create the var HRCK7 */
COMPUTE HRCK7=-4
DO IF ((BUS2 EQ 2 OR BUS2 EQ -2 OR BUS2 EQ -1) AND (HRACT1 LT 15 OR HRACT1 EQ -2))
COMPUTE HRCK7=1
ELSE IF ((BUS2 EQ 2 OR BUS2 EQ -2 OR BUS2 EQ -1) AND HRACT1 GE 15)
COMPUTE HRCK7=2
ELSE IF ((HRUSLT GE 35 OR HRFTPT EQ 1) AND HRACTT LT 35 AND (HRACT1 NE -1 OR 
                    HRACT1 NE -2 OR HRACT2 NE -1 OR HRACT2 NE -2)) 
COMPUTE HRCK7=3
ELSE IF (HRWANT EQ 1 AND HRACTT LT 35 AND (HRRSN1 EQ 1 OR HRRSN1 EQ 2 OR HRRSN1 EQ 3))
COMPUTE HRCK7=4
ELSE 
COMPUTE HRCK7=5
END IF 
 
/* the following lines create the var ABSOT */
DO IF (HRACT1 EQ 0 AND HRACT2 EQ 0)
COMPUTE ABSOT=1
ELSE
COMPUTE ABSOT=0
END IF
 
/* the following lines create the var HRCK6 */
COMPUTE HRCK6=-4
DO IF ((HRACT1 EQ 0 AND HRACT2 EQ 0) AND (BUS2 EQ 2 OR BUS2 EQ -1 OR BUS2 EQ -2))
COMPUTE HRCK6=1
ELSE IF (ABSOT EQ 1)
COMPUTE HRCK6=2
ELSE 
COMPUTE HRCK6=3
END IF
 
/* the following lines create the var WK */
COMPUTE WK=-4
DO IF (R(52318.) NE -4)
COMPUTE WK=R(52318.)
ELSE IF (R(52319.) NE -4)
COMPUTE WK=R(52319.)
END IF
 
/* the following lines create the var RETOT */
DO IF (WK EQ 3)
COMPUTE RETOT=1
ELSE
COMPUTE RETOT=0
END IF
 
/* the following lines rename the vars */
COMPUTE BUS1=R(52321.)
COMPUTE RET1=R(52335.)
COMPUTE IO1COW=R(52314.)
COMPUTE NLFACT=R(52578.)
 
/* the following lines create additional variables */
 
DO IF (Q5B2_22 NE -4)
COMPUTE ABSPD=Q5B2_22
ELSE IF (R(52481.) NE -4)
COMPUTE ABSPD=R(52481.)
ELSE
COMPUTE ABSPD=R(52354.)
END IF
 
DO IF (Q5B2_65 NE -4)
COMPUTE LKAVL=Q5B2_65
ELSE IF (R(52515.) NE -4)
COMPUTE LKAVL=R(52515.)
ELSE
COMPUTE LKAVL=R(52437.)
END IF
 
DO IF (Q5B2_51 NE -4)
COMPUTE LAYAVL=Q5B2_51
ELSE IF (Q5B_51 NE -4)
COMPUTE LAYAVL=Q5B_51
ELSE
COMPUTE LAYAVL=R(52410.)
END IF
 
DO IF (Q5B2_66 NE -4)
COMPUTE LKAVR=Q5B2_66
ELSE IF (Q5B_66 NE -4)
COMPUTE LKAVR=Q5B_66
ELSE
COMPUTE LKAVR=R(45540.)
END IF
 
DO IF (Q5B2_52 NE -4)
COMPUTE LAYAVR=Q5B2_52
ELSE IF (Q5B_52 NE -4)
COMPUTE LAYAVR=Q5B_52
ELSE
COMPUTE LAYAVR=R(52411.)
END IF
 
DO IF (Q5B2_60 NE -4)
COMPUTE LK=Q5B2_60
ELSE IF (R(52503.) NE -4)
COMPUTE LK=R(52503.)
ELSE
COMPUTE LK=R(52420.)
END IF
 
DO IF (Q5B2_11 NE -4)
COMPUTE DIS1=Q5B2_11
ELSE IF (R(52455.) NE -4)
COMPUTE DIS1=R(52455.)
ELSE
COMPUTE DIS1=R(52336.)
END IF
 
DO IF (Q5B2_12 NE -4)
COMPUTE DIS2=Q5B2_12
ELSE IF (R(52456.) NE -4)
COMPUTE DIS2=R(52456.)
ELSE
COMPUTE DIS2=R(52337.)
END IF
 
/* the following lines create the var DWWNTO */
DO IF (RET1 EQ 1)
COMPUTE DWWNTO=1
 
ELSE IF (Q5B2_78 EQ 1)
COMPUTE DWWNTO=1
ELSE IF (Q5B2_78 EQ 0)
COMPUTE DWWNTO=2
ELSE IF (Q5B2_78 EQ -2)
COMPUTE DWWNTO=-2
ELSE IF (Q5B2_78 EQ -1)
COMPUTE DWWNTO=-1
ELSE IF (Q5B2_78 EQ 3)
COMPUTE DWWNTO=3
ELSE IF (Q5B2_78 EQ 4)
COMPUTE DWWNTO=4
ELSE IF (Q5BCK_78 EQ 1)
COMPUTE DWWNTO=1
ELSE IF (Q5BCK_78 EQ 0)
COMPUTE DWWNTO=2
ELSE IF (Q5BCK_78 EQ -2)
COMPUTE DWWNTO=-2
ELSE IF (Q5BCK_78 EQ -1)
COMPUTE DWWNTO=-1
ELSE IF (Q5BCK_78 EQ 3)
COMPUTE DWWNTO=3
ELSE IF (Q5BCK_78 EQ 4)
COMPUTE DWWNTO=4
ELSE IF (Q5_78 EQ 1)
COMPUTE DWWNTO=1
ELSE IF (Q5_78 EQ 0)
COMPUTE DWWNTO=2
ELSE IF (Q5_78 EQ -2)
COMPUTE DWWNTO=-2
ELSE IF (Q5_78 EQ -1)
COMPUTE DWWNTO=-1
ELSE IF (Q5_78 EQ 3)
COMPUTE DWWNTO=3
ELSE IF (Q5_78 EQ 4)
COMPUTE DWWNTO=4
ELSE
COMPUTE DWWNTO=-3
END IF
 
/* the following lines create the var DIS */
DO IF (Q5_9A4 EQ -4)
COMPUTE DIS=-4
ELSE IF (Q5_9D EQ -1 OR Q5_9E EQ -1 OR Q5_9F EQ -1 OR Q5_9G EQ -1) OR (Q5_9D EQ -2 OR 
                    Q5_9E EQ -2 OR Q5_9F EQ -2 OR Q5_9G EQ -2)
COMPUTE DIS=-2
ELSE IF (Q5_9A4 EQ 1 AND Q5_9D EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9D EQ 0)
COMPUTE DIS=0
ELSE IF (Q5_9A5 EQ 1 AND Q5_9E EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9E EQ 0)
COMPUTE DIS=0
ELSE IF (Q5_9A6 EQ 1 AND Q5_9F EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9F EQ 0)
COMPUTE DIS=0
ELSE IF (Q5_9A7 EQ 1 AND Q5_9G EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9G EQ 0)
COMPUTE DIS=0
ELSE 
COMPUTE DIS=-3
END IF
 
/* the following lines create IO1COW */
DO IF (R(52314.) EQ 1)
COMPUTE IO1COW=8
ELSE
COMPUTE IO1COW=0
END IF
 
/* the following lines create the ESR var approximating MLR */
DO IF ((WK EQ 1 AND (HRCK6 EQ 3 OR HRCK6 EQ -4 OR HRCK6 EQ 99 OR HRCK6 EQ 999)) OR 
                    (BUS1 EQ 1 AND (HRCK7 EQ 2 OR HRCK7 EQ 3 OR HRCK7 EQ 4 OR HRCK7 EQ 5 OR 
                    HRCK7 EQ -4)))
COMPUTE ESR=1
ELSE IF (ABSPD EQ 1 OR ABSPD EQ 0 OR ABSPD EQ -1 OR ABSPD EQ -2)
COMPUTE ESR=2
ELSE IF ((LAYAVL EQ 1 OR LAYAVL EQ -1 OR LAYAVL EQ -2) OR LAYAVR EQ 1)
COMPUTE ESR=3
ELSE IF ((LKAVL EQ 1 OR LKAVL EQ -1 OR LKAVL EQ -2) OR (LKAVR EQ 1 OR LKAVR EQ 2))
COMPUTE ESR=4
ELSE IF ((WK EQ 3 AND AGE GE 50 AND RET1 EQ 1 AND LK EQ 1 AND LKAVL EQ 0 AND 
                    (LKAVR EQ 3 OR LKAVR EQ 4 OR LKAVR EQ -1 OR LKAVR EQ -2)) OR             (RET1 EQ 0 OR 
                    LK EQ 3 OR DWWNTO EQ 3) OR NLFACT EQ 5 OR RETOT EQ 1) 
COMPUTE ESR=5
ELSE IF (DIS1 EQ 1 OR DIS2 EQ 1 OR DIS EQ 1)
COMPUTE ESR=6
ELSE IF (R(52314.) EQ 1)
COMPUTE ESR=8
ELSE
COMPUTE ESR=7
END IF 
 
          ESR(6)=R(15199.);
          ESR(7)=R(18906.);
          ESR(8)=R(22577.);
          ESR(9)=R(24451.);
          ESR(10)=R(28706.);
          ESR(11)=R(30743.);
          ESR(12)=R(34010.);
          ESR(13)=R(36564.);
          ESR(14)=R(40069.);
          ESR(15)=R(44180.);
          ESR(16)=R(50810.);
          ESR(17)=R(51663.);
          ESRC(6)=R(15199.01);
          ESRC(7)=R(18906.01);
          ESRC(8)=R(22577.01);
          ESRC(9)=R(24451.01);
          ESRC(10)=R(28707.);
          ESRC(11)=R(30744.);
          ESRC(12)=R(34011.);
          EARC(13)=R(36565.);
          EARC(14)=R(40070.);
          ESRC(15)=R(44181.);
          ESRC(16)=R(50811.);
          ESRC(17)=R(51664.);

 

1998 VARIABLES

/* The programming for the new 1998 ESR variables is done in SPSS */
 
/* the following lines create the var AGE */
COMPUTE AGE=41
 
/* the following lines construct the var HRACT1 */
DO IF (Q5B2_40A EQ -4)
COMPUTE HRACT1=-4
ELSE IF (Q5B2_41A EQ -1 OR Q5B2_41B EQ -1 OR Q5B2_41C EQ -1 OR Q5B2_41D EQ -1
                     OR Q5B2_41A EQ -2 OR Q5B2_41B EQ -2 OR Q5B2_41C EQ -2 OR 
         Q5B2_41D EQ -2)
COMPUTE HRACT1=-2
ELSE IF (Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR 
         Q5B2_41D EQ 995)
COMPUTE HRACT1=995
ELSE IF (Q5B2_40B EQ 1 AND Q5B2_41A NE -4)
COMPUTE HRACT1=Q5B2_41A
ELSE IF (Q5B2_40C EQ 1 AND Q5B2_41B NE -4)
COMPUTE HRACT1=Q5B2_41B
ELSE IF (Q5B2_40D EQ 1 AND Q5B2_41C NE -4)
COMPUTE HRACT1=Q5B2_41C
ELSE IF (Q5B2_40E EQ 1 OR Q5B2_40E EQ 0)
COMPUTE HRACT1=Q5B2_41D
 
ELSE IF (Q5B_40A EQ -4)
COMPUTE HRACT1=-4
ELSE IF (Q5B_41A EQ -1 OR Q5B_41B EQ -1 OR Q5B_41C EQ -1 OR Q5B_41D EQ -1
                     OR Q5B_41A EQ -2 OR Q5B_41B EQ -2 OR Q5B_41C EQ -2 OR 
         Q5B_41D EQ -2)
COMPUTE HRACT1=-2
ELSE IF (Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR 
         Q5B_41D EQ 995)
COMPUTE HRACT1=995
ELSE IF (Q5B_40B EQ 1 AND Q5B_41A NE -4)
COMPUTE HRACT1=Q5B_41A
ELSE IF (Q5B_40C EQ 1 AND Q5B_41B NE -4)
COMPUTE HRACT1=Q5B_41B
ELSE IF (Q5B_40D EQ 1 AND Q5B_41C NE -4)
COMPUTE HRACT1=Q5B_41C
ELSE IF (Q5B_40E EQ 1 OR Q5B_40E EQ 0)
COMPUTE HRACT1=Q5B_41D
 
ELSE IF (Q5_40A EQ -4)
COMPUTE HRACT1=-4
ELSE IF (Q5_41A EQ -1 OR Q5_41B EQ -1 OR Q5_41C EQ -1 OR Q5_41D EQ -1
                     OR Q5_41A EQ -2 OR Q5_41B EQ -2 OR Q5_41C EQ -2 OR Q5_41D EQ -2)
COMPUTE HRACT1=-2
ELSE IF (Q5_41A EQ 995 OR Q5_41B EQ 995 OR Q5_41C EQ 995 OR Q5_41D EQ 995)
COMPUTE HRACT1=995
ELSE IF (Q5_40B EQ 1 AND Q5_41A NE -4)
COMPUTE HRACT1=Q5_41A
ELSE IF (Q5_40C EQ 1 AND Q5_41B NE -4)
COMPUTE HRACT1=Q5_41B
ELSE IF (Q5_40D EQ 1 AND Q5_41C NE -4)
COMPUTE HRACT1=Q5_41C
ELSE IF (Q5_40E EQ 1 OR Q5_40E EQ 0)
COMPUTE HRACT1=Q5_41D
ELSE
COMPUTE HRACT1=-3
END IF
 
/* the following lines construct the var HRACT2 */
DO IF (Q5B2_42 EQ -4 OR Q5B2_42 EQ 0)
COMPUTE HRACT2=-4
ELSE IF (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1
                    OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2)
COMPUTE HRACT2=-2
ELSE IF (Q5B2_43A EQ 995 OR Q5B2_43B EQ 995)
COMPUTE HRACT2=995
ELSE IF (Q5B2_43 EQ 1)
COMPUTE HRACT2=Q5B2_43A
ELSE IF (Q5B2_42 EQ 1 AND Q5B2_43 EQ 0)
COMPUTE HRACT2=Q5B2_43B
 
ELSE IF (Q5B_42 EQ -4 OR Q5B_42 EQ 0)
COMPUTE HRACT2=-4
ELSE IF (Q5B_43A EQ -1 OR Q5B_43B EQ -1
                    OR Q5B_43A EQ -2 OR Q5B_43B EQ -2)
COMPUTE HRACT2=-2
ELSE IF (Q5B_43A EQ 995 OR Q5B_43B EQ 995)
COMPUTE HRACT2=995
ELSE IF (Q5B_43 EQ 1)
COMPUTE HRACT2=Q5B_43A
ELSE IF (Q5B_42 EQ 1 AND Q5B_43 EQ 0)
COMPUTE HRACT2=Q5B_43B
 
ELSE IF (Q5_42 EQ -4 OR Q5_42 EQ 0)
COMPUTE HRACT2=-4
ELSE IF (Q5_43A EQ -1 OR Q5_43B EQ -1
                    OR Q5_43A EQ -2 OR Q5_43B EQ -2)
COMPUTE HRACT2=-2
ELSE IF (Q5_43A EQ 995 OR Q5_43B EQ 995)
COMPUTE HRACT2=995
ELSE IF (Q5_43 EQ 1)
COMPUTE HRACT2=Q5_43A
ELSE IF (Q5_42 EQ 1 AND Q5_43 EQ 0)
COMPUTE HRACT2=Q5_43B
ELSE 
COMPUTE HRACT2=-3
END IF
 
/* the following lines create the var HRACTT */
DO IF (Q5B2_40A EQ -4)
COMPUTE HRACTT=-4
ELSE IF ((Q5B2_41A EQ -1 OR Q5B2_41B EQ -1 OR Q5B2_41C EQ -1 OR 
        Q5B2_41D EQ -1 OR Q5B2_41A EQ -2 OR Q5B2_41B EQ -2 OR 
        Q5B2_41C EQ -2 OR Q5B2_41D EQ -2) AND (Q5B2_43A EQ -1 OR 
        Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2))
COMPUTE HRACTT=-2
ELSE IF ((Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR 
        Q5B2_41D EQ 995) AND (Q5B2_43A EQ 995 OR Q5B2_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B2_41A EQ -1 OR Q5B2_41B EQ -1 OR Q5B2_41C EQ -1 OR 
        Q5B2_41D EQ -1 OR Q5B2_41A EQ -2 OR Q5B2_41B EQ -2 OR 
        Q5B2_41C EQ -2 OR Q5B2_41D EQ -2) AND (Q5B2_43A EQ 995 OR 
        Q5B2_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR 
        Q5B2_41D EQ 995 OR Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR 
        Q5B2_41C EQ 995 OR Q5B2_41D EQ 995) AND (Q5B2_43A EQ -1 OR 
        Q5B2_43B EQ -1 OR Q5B2_43A EQ -2 OR Q5B2_43B EQ -2))
COMPUTE HRACTT=995
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND 
        Q5B2_41A NE 995) AND (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR 
        Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR Q5B2_43A EQ 995 OR 
        Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41A
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND 
        Q5B2_41B NE 995) AND (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR 
        Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR Q5B2_43A EQ 995 OR 
        Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41B
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND 
        Q5B2_41C NE 995) AND (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR 
        Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR Q5B2_43A EQ 995 OR 
        Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41C
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND 
        Q5B2_41D NE 995) AND (Q5B2_43A EQ -1 OR Q5B2_43B EQ -1 OR 
        Q5B2_43A EQ -2 OR Q5B2_43B EQ -2 OR Q5B2_43A EQ 995 OR 
        Q5B2_43B EQ 995))
COMPUTE HRACTT=Q5B2_41D
ELSE IF ((Q5B2_43B NE -4 AND Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND 
        Q5B2_43A NE 995) AND (Q5B2_41A EQ -1 OR Q5B2_41A EQ -2 OR 
        Q5B2_41A EQ 995 OR Q5B2_41B EQ -1 OR Q5B2_41B EQ -2 OR 
        Q5B2_41B EQ 995 OR Q5B2_41C EQ -1 OR Q5B2_41C EQ -2 OR 
        Q5B2_41C EQ 995 OR Q5B2_41D EQ -1 OR Q5B2_41D EQ -2 OR 
        Q5B2_41D EQ 995))
COMPUTE HRACTT=Q5B2_43A
ELSE IF ((Q5B2_43A NE -4 AND Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND 
        Q5B2_43B NE 995) AND (Q5B2_41A EQ -1 OR Q5B2_41A EQ -2 OR 
        Q5B2_41A EQ 995 OR Q5B2_41B EQ -1 OR Q5B2_41B EQ -2 OR 
        Q5B2_41B EQ 995 OR Q5B2_41C EQ -1 OR Q5B2_41C EQ -2 OR 
        Q5B2_41C EQ 995 OR Q5B2_41D EQ -1 OR Q5B2_41D EQ -2 OR 
        Q5B2_41D EQ 995))
COMPUTE HRACTT=Q5B2_43B
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND 
        Q5B2_41A NE 995) AND (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND 
        Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41A+Q5B2_43A
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND 
        Q5B2_41A NE 995) AND (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND 
        Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41A+Q5B2_43B
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND 
        Q5B2_41B NE 995) AND (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND 
        Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41B+Q5B2_43A
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND 
        Q5B2_41B NE 995) AND (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND 
        Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41B+Q5B2_43B
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND 
        Q5B2_41C NE 995) AND (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND 
        Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41C+Q5B2_43A
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND 
        Q5B2_41C NE 995) AND (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND 
        Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41C+Q5B2_43B
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND 
        Q5B2_41D NE 995) AND (Q5B2_43A NE -1 AND Q5B2_43A NE -2 AND 
        Q5B2_43A NE 995 AND Q5B2_43A NE -4)) 
COMPUTE HRACTT=Q5B2_41D+Q5B2_43A
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND 
        Q5B2_41D NE 995) AND (Q5B2_43B NE -1 AND Q5B2_43B NE -2 AND 
        Q5B2_43B NE 995 AND Q5B2_43B NE -4)) 
COMPUTE HRACTT=Q5B2_41D+Q5B2_43B
ELSE IF ((Q5B2_41A NE -4 AND Q5B2_41A NE -1 AND Q5B2_41A NE -2 AND 
        Q5B2_41A NE 995) AND Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41A
ELSE IF ((Q5B2_41B NE -4 AND Q5B2_41B NE -1 AND Q5B2_41B NE -2 AND 
        Q5B2_41B NE 995) AND Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41B
ELSE IF ((Q5B2_41C NE -4 AND Q5B2_41C NE -1 AND Q5B2_41C NE -2 AND 
        Q5B2_41C NE 995) AND Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41C
ELSE IF ((Q5B2_41D NE -4 AND Q5B2_41D NE -1 AND Q5B2_41D NE -2 AND 
        Q5B2_41D NE 995) AND Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=Q5B2_41D
ELSE IF ((Q5B2_41A EQ -1 OR Q5B2_41A EQ -2 OR Q5B2_41B EQ -1 OR Q5B2_41B EQ -2
                    OR Q5B2_41C EQ -1 OR Q5B2_41C EQ -2 OR Q5B2_41D EQ -1 OR 
        Q5B2_41D EQ -2) AND Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=-2
ELSE IF ((Q5B2_41A EQ 995 OR Q5B2_41B EQ 995 OR Q5B2_41C EQ 995 OR 
        Q5B2_41D EQ 995) AND Q5B2_43A EQ -4 AND Q5B2_43B EQ -4)
COMPUTE HRACTT=995
 
ELSE IF (Q5B_40A EQ -4)
COMPUTE HRACTT=-4
ELSE IF ((Q5B_41A EQ -1 OR Q5B_41B EQ -1 OR Q5B_41C EQ -1 OR 
        Q5B_41D EQ -1 OR Q5B_41A EQ -2 OR Q5B_41B EQ -2 OR 
        Q5B_41C EQ -2 OR Q5B_41D EQ -2) AND (Q5B_43A EQ -1 OR 
        Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2))
COMPUTE HRACTT=-2
ELSE IF ((Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR 
        Q5B_41D EQ 995) AND (Q5B_43A EQ 995 OR Q5B_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B_41A EQ -1 OR Q5B_41B EQ -1 OR Q5B_41C EQ -1 OR 
        Q5B_41D EQ -1 OR Q5B_41A EQ -2 OR Q5B_41B EQ -2 OR 
        Q5B_41C EQ -2 OR Q5B_41D EQ -2) AND (Q5B_43A EQ 995 OR 
        Q5B_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR 
        Q5B_41D EQ 995 OR Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR 
        Q5B_41C EQ 995 OR Q5B_41D EQ 995) AND (Q5B_43A EQ -1 OR 
        Q5B_43B EQ -1 OR Q5B_43A EQ -2 OR Q5B_43B EQ -2))
COMPUTE HRACTT=995
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND 
        Q5B_41A NE 995) AND (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR 
        Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR 
        Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41A
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND 
        Q5B_41B NE 995) AND (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR 
        Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR 
        Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41B
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND 
        Q5B_41C NE 995) AND (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR 
        Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR 
        Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41C
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND 
        Q5B_41D NE 995) AND (Q5B_43A EQ -1 OR Q5B_43B EQ -1 OR 
        Q5B_43A EQ -2 OR Q5B_43B EQ -2 OR Q5B_43A EQ 995 OR 
        Q5B_43B EQ 995))
COMPUTE HRACTT=Q5B_41D
ELSE IF ((Q5B_43B NE -4 AND Q5B_43A NE -1 AND Q5B_43A NE -2 AND 
        Q5B_43A NE 995) AND (Q5B_41A EQ -1 OR Q5B_41A EQ -2 OR 
        Q5B_41A EQ 995 OR Q5B_41B EQ -1 OR Q5B_41B EQ -2 OR 
        Q5B_41B EQ 995 OR Q5B_41C EQ -1 OR Q5B_41C EQ -2 OR 
        Q5B_41C EQ 995 OR Q5B_41D EQ -1 OR Q5B_41D EQ -2 OR 
        Q5B_41D EQ 995))
COMPUTE HRACTT=Q5B_43A
ELSE IF ((Q5B_43A NE -4 AND Q5B_43B NE -1 AND Q5B_43B NE -2 AND 
        Q5B_43B NE 995) AND (Q5B_41A EQ -1 OR Q5B_41A EQ -2 OR 
        Q5B_41A EQ 995 OR Q5B_41B EQ -1 OR Q5B_41B EQ -2 OR 
        Q5B_41B EQ 995 OR Q5B_41C EQ -1 OR Q5B_41C EQ -2 OR 
        Q5B_41C EQ 995 OR Q5B_41D EQ -1 OR Q5B_41D EQ -2 OR 
        Q5B_41D EQ 995))
COMPUTE HRACTT=Q5B_43B
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND 
        Q5B_41A NE 995) AND (Q5B_43A NE -1 AND Q5B_43A NE -2 AND 
        Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41A+Q5B_43A
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND 
        Q5B_41A NE 995) AND (Q5B_43B NE -1 AND Q5B_43B NE -2 AND 
        Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41A+Q5B_43B
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND 
        Q5B_41B NE 995) AND (Q5B_43A NE -1 AND Q5B_43A NE -2 AND 
        Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41B+Q5B_43A
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND 
        Q5B_41B NE 995) AND (Q5B_43B NE -1 AND Q5B_43B NE -2 AND 
        Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41B+Q5B_43B
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND 
        Q5B_41C NE 995) AND (Q5B_43A NE -1 AND Q5B_43A NE -2 AND 
        Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41C+Q5B_43A
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND 
        Q5B_41C NE 995) AND (Q5B_43B NE -1 AND Q5B_43B NE -2 AND 
        Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41C+Q5B_43B
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND 
        Q5B_41D NE 995) AND (Q5B_43A NE -1 AND Q5B_43A NE -2 AND 
        Q5B_43A NE 995 AND Q5B_43A NE -4)) 
COMPUTE HRACTT=Q5B_41D+Q5B_43A
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND 
        Q5B_41D NE 995) AND (Q5B_43B NE -1 AND Q5B_43B NE -2 AND 
        Q5B_43B NE 995 AND Q5B_43B NE -4)) 
COMPUTE HRACTT=Q5B_41D+Q5B_43B
ELSE IF ((Q5B_41A NE -4 AND Q5B_41A NE -1 AND Q5B_41A NE -2 AND 
        Q5B_41A NE 995) AND Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41A
ELSE IF ((Q5B_41B NE -4 AND Q5B_41B NE -1 AND Q5B_41B NE -2 AND 
        Q5B_41B NE 995) AND Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41B
ELSE IF ((Q5B_41C NE -4 AND Q5B_41C NE -1 AND Q5B_41C NE -2 AND 
        Q5B_41C NE 995) AND Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41C
ELSE IF ((Q5B_41D NE -4 AND Q5B_41D NE -1 AND Q5B_41D NE -2 AND 
        Q5B_41D NE 995) AND Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=Q5B_41D
ELSE IF ((Q5B_41A EQ -1 OR Q5B_41A EQ -2 OR Q5B_41B EQ -1 OR Q5B_41B EQ -2
                    OR Q5B_41C EQ -1 OR Q5B_41C EQ -2 OR Q5B_41D EQ -1 OR 
        Q5B_41D EQ -2) AND Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=-2
ELSE IF ((Q5B_41A EQ 995 OR Q5B_41B EQ 995 OR Q5B_41C EQ 995 OR 
        Q5B_41D EQ 995) AND Q5B_43A EQ -4 AND Q5B_43B EQ -4)
COMPUTE HRACTT=995
 
ELSE IF (Q5_40A EQ -4)
COMPUTE HRACTT=-4
ELSE IF ((Q5_41A EQ -1 OR Q5_41B EQ -1 OR Q5_41C EQ -1 OR Q5_41D EQ -1 OR
                    Q5_41A EQ -2 OR Q5_41B EQ -2 OR Q5_41C EQ -2 OR Q5_41D EQ -2) AND
                    (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2))
COMPUTE HRACTT=-2
ELSE IF ((Q5_41A EQ 995 OR Q5_41B EQ 995 OR Q5_41C EQ 995 OR Q5_41D EQ 995)
                    AND (Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5_41A EQ -1 OR Q5_41B EQ -1 OR Q5_41C EQ -1 OR Q5_41D EQ -1 OR
                    Q5_41A EQ -2 OR Q5_41B EQ -2 OR Q5_41C EQ -2 OR Q5_41D EQ -2) AND
                    (Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT=995
ELSE IF ((Q5_41A EQ 995 OR Q5_41B EQ 995 OR Q5_41C EQ 995 OR Q5_41D EQ 995 OR
                    Q5_41A EQ 995 OR Q5_41B EQ 995 OR Q5_41C EQ 995 OR Q5_41D EQ 995) AND
                    (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2))
COMPUTE HRACTT=995
ELSE IF ((Q5_41A NE -4 AND Q5_41A NE -1 AND Q5_41A NE -2 AND Q5_41A NE 995)
                     AND (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2 
                    OR Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT=Q5_41A
ELSE IF ((Q5_41B NE -4 AND Q5_41B NE -1 AND Q5_41B NE -2 AND Q5_41B NE 995) 
                    AND (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2 
                    OR Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT=Q5_41B
ELSE IF ((Q5_41C NE -4 AND Q5_41C NE -1 AND Q5_41C NE -2 AND Q5_41C NE 995) 
                    AND (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2 
                    OR Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT=Q5_41C
ELSE IF ((Q5_41D NE -4 AND Q5_41D NE -1 AND Q5_41D NE -2 AND Q5_41D NE 995) 
                    AND (Q5_43A EQ -1 OR Q5_43B EQ -1 OR Q5_43A EQ -2 OR Q5_43B EQ -2 
                    OR Q5_43A EQ 995 OR Q5_43B EQ 995))
COMPUTE HRACTT=Q5_41D
ELSE IF ((Q5_43B NE -4 AND Q5_43A NE -1 AND Q5_43A NE -2 AND Q5_43A NE 995) 
                    AND (Q5_41A EQ -1 OR Q5_41A EQ -2 OR Q5_41A EQ 995 OR Q5_41B EQ -1 
                    OR Q5_41B EQ -2 OR Q5_41B EQ 995 OR 
                    Q5_41C EQ -1 OR Q5_41C EQ -2 OR Q5_41C EQ 995 OR Q5_41D EQ -1 
                    OR Q5_41D EQ -2 OR Q5_41D EQ 995))
COMPUTE HRACTT=Q5_43A
ELSE IF ((Q5_43A NE -4 AND Q5_43B NE -1 AND Q5_43B NE -2 AND Q5_43B NE 995) 
                    AND (Q5_41A EQ -1 OR Q5_41A EQ -2 OR Q5_41A EQ 995 OR Q5_41B EQ -1 
                    OR Q5_41B EQ -2 OR Q5_41B EQ 995 OR 
                    Q5_41C EQ -1 OR Q5_41C EQ -2 OR Q5_41C EQ 995 OR Q5_41D EQ -1 
                    OR Q5_41D EQ -2 OR Q5_41D EQ 995))
COMPUTE HRACTT=Q5_43B
ELSE IF ((Q5_41A NE -4 AND Q5_41A NE -1 AND Q5_41A NE -2 AND Q5_41A NE 995) 
                    AND (Q5_43A NE -1 AND Q5_43A NE -2 AND Q5_43A NE 995 AND Q5_43A NE -4)) 
COMPUTE HRACTT=Q5_41A+Q5_43A
ELSE IF ((Q5_41A NE -4 AND Q5_41A NE -1 AND Q5_41A NE -2 AND Q5_41A NE 995) 
                    AND (Q5_43B NE -1 AND Q5_43B NE -2 AND Q5_43B NE 995 AND Q5_43B NE -4)) 
COMPUTE HRACTT=Q5_41A+Q5_43B
ELSE IF ((Q5_41B NE -4 AND Q5_41B NE -1 AND Q5_41B NE -2 AND Q5_41B NE 995) 
                    AND (Q5_43A NE -1 AND Q5_43A NE -2 AND Q5_43A NE 995 AND Q5_43A NE -4)) 
COMPUTE HRACTT=Q5_41B+Q5_43A
ELSE IF ((Q5_41B NE -4 AND Q5_41B NE -1 AND Q5_41B NE -2 AND Q5_41B NE 995) 
                    AND (Q5_43B NE -1 AND Q5_43B NE -2 AND Q5_43B NE 995 AND Q5_43B NE -4)) 
COMPUTE HRACTT=Q5_41B+Q5_43B
ELSE IF ((Q5_41C NE -4 AND Q5_41C NE -1 AND Q5_41C NE -2 AND Q5_41C NE 995) 
                    AND (Q5_43A NE -1 AND Q5_43A NE -2 AND Q5_43A NE 995 AND Q5_43A NE -4)) 
COMPUTE HRACTT=Q5_41C+Q5_43A
ELSE IF ((Q5_41C NE -4 AND Q5_41C NE -1 AND Q5_41C NE -2 AND Q5_41C NE 995) 
                    AND (Q5_43B NE -1 AND Q5_43B NE -2 AND Q5_43B NE 995 AND Q5_43B NE -4)) 
COMPUTE HRACTT=Q5_41C+Q5_43B
ELSE IF ((Q5_41D NE -4 AND Q5_41D NE -1 AND Q5_41D NE -2 AND Q5_41D NE 995) 
                    AND (Q5_43A NE -1 AND Q5_43A NE -2 AND Q5_43A NE 995 AND Q5_43A NE -4)) 
COMPUTE HRACTT=Q5_41D+Q5_43A
ELSE IF ((Q5_41D NE -4 AND Q5_41D NE -1 AND Q5_41D NE -2 AND Q5_41D NE 995) 
                    AND (Q5_43B NE -1 AND Q5_43B NE -2 AND Q5_43B NE 995 AND Q5_43B NE -4)) 
COMPUTE HRACTT=Q5_41D+Q5_43B
ELSE IF ((Q5_41A NE -4 AND Q5_41A NE -1 AND Q5_41A NE -2 AND Q5_41A NE 995) 
                    AND Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT=Q5_41A
ELSE IF ((Q5_41B NE -4 AND Q5_41B NE -1 AND Q5_41B NE -2 AND Q5_41B NE 995) 
                    AND Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT=Q5_41B
ELSE IF ((Q5_41C NE -4 AND Q5_41C NE -1 AND Q5_41C NE -2 AND Q5_41C NE 995) 
                    AND Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT=Q5_41C
ELSE IF ((Q5_41D NE -4 AND Q5_41D NE -1 AND Q5_41D NE -2 AND Q5_41D NE 995) 
                    AND Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT=Q5_41D
ELSE IF ((Q5_41A EQ -1 OR Q5_41A EQ -2 OR Q5_41B EQ -1 OR Q5_41B EQ -2
                    OR Q5_41C EQ -1 OR Q5_41C EQ -2 OR Q5_41D EQ -1 OR Q5_41D EQ -2) 
                    AND Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT=-2
ELSE IF ((Q5_41A EQ 995 OR Q5_41B EQ 995 OR Q5_41C EQ 995 OR Q5_41D EQ 995)
                    AND Q5_43A EQ -4 AND Q5_43B EQ -4)
COMPUTE HRACTT=995
ELSE 
COMPUTE HRACTT=-3
END IF
 
/* the following lines creates the var BUS2 */
DO IF (Q5_6 EQ -4)
COMPUTE BUS2=-4
ELSE IF (Q5_6 EQ -1)
COMPUTE BUS2=-1
ELSE IF (Q5_6 EQ -2)
COMPUTE BUS2=-2
ELSE IF (Q5_7 EQ -1 OR Q5_8 EQ -1)
COMPUTE BUS2=-1
ELSE IF (Q5_7 EQ -2 OR Q5_8 EQ -2)
COMPUTE BUS2=-2
ELSE IF (Q5_7 EQ 1 OR Q5_8 EQ 1)
COMPUTE BUS2=1
ELSE IF (Q5_8 EQ 0)
COMPUTE BUS2=2  /* this should normally be 0 */
ELSE 
COMPUTE BUS2=-3
END IF
 
/* the following lines create the var HRUSL1 */
DO IF (Q5B2_25 EQ -4)
COMPUTE HRUSL1=-4
ELSE IF (Q5B2_26A EQ -1 OR Q5B2_26C EQ -1 OR Q5B2_26A EQ -2 OR Q5B2_26C EQ -2)
COMPUTE HRUSL1=-2
ELSE IF (Q5B2_26A EQ 995 OR Q5B2_26C EQ 995)
COMPUTE HRUSL1=995
ELSE IF (Q5B2_26A EQ 1)
COMPUTE HRUSL1=Q5B2_26B
ELSE IF (Q5B2_26C EQ 1)
COMPUTE HRUSL1=Q5B2_26D
 
ELSE IF (Q5B_25 EQ -4)
COMPUTE HRUSL1=-4
ELSE IF (Q5B_26A EQ -1 OR Q5B_26C EQ -1 OR Q5B_26A EQ -2 OR Q5B_26C EQ -2)
COMPUTE HRUSL1=-2
ELSE IF (Q5B_26A EQ 995 OR Q5B_26C EQ 995)
COMPUTE HRUSL1=995
ELSE IF (Q5B_26A EQ 1)
COMPUTE HRUSL1=Q5B_26B
ELSE IF (Q5B_26C EQ 1)
COMPUTE HRUSL1=Q5B_26D
 
ELSE IF (Q5_25 EQ -4)
COMPUTE HRUSL1=-4
ELSE IF (Q5_26A EQ -1 OR Q5_26C EQ -1 OR Q5_26A EQ -2 OR Q5_26C EQ -2)
COMPUTE HRUSL1=-2
ELSE IF (Q5_26A EQ 995 OR Q5_26C EQ 995)
COMPUTE HRUSL1=995
ELSE IF (Q5_26A EQ 1)
COMPUTE HRUSL1=Q5_26B
ELSE IF (Q5_26C EQ 1)
COMPUTE HRUSL1=Q5_26D
ELSE 
COMPUTE HRUSL1=-3
END IF
 
/* the following lines create the var HRUSL2 */
DO IF (Q5B2_28A EQ -4)
COMPUTE HRUSL2=-4
ELSE IF (Q5B2_28B EQ -1 OR Q5B2_28D EQ -1 OR Q5B2_28B EQ -2 OR Q5B2_28D EQ -2)
COMPUTE HRUSL2=-2
ELSE IF (Q5B2_28B EQ 995 OR Q5B2_28D EQ 995)
COMPUTE HRUSL2=995
ELSE IF (Q5B2_28B EQ 1)
COMPUTE HRUSL2=Q5B2_28C
ELSE IF (Q5B2_28D EQ 1)
COMPUTE HRUSL2=Q5B2_28E
 
ELSE IF (Q5B_28A EQ -4)
COMPUTE HRUSL2=-4
ELSE IF (Q5B_28B EQ -1 OR Q5B_28D EQ -1 OR Q5B_28B EQ -2 OR Q5B_28D EQ -2)
COMPUTE HRUSL2=-2
ELSE IF (Q5B_28B EQ 995 OR Q5B_28D EQ 995)
COMPUTE HRUSL2=995
ELSE IF (Q5B_28B EQ 1)
COMPUTE HRUSL2=Q5B_28C
ELSE IF (Q5B_28D EQ 1)
COMPUTE HRUSL2=Q5B_28E
 
ELSE IF (Q5_28A EQ -4)
COMPUTE HRUSL2=-4
ELSE IF (Q5_28B EQ -1 OR Q5_28D EQ -1 OR Q5_28B EQ -2 OR Q5_28D EQ -2)
COMPUTE HRUSL2=-2
ELSE IF (Q5_28B EQ 995 OR Q5_28D EQ 995)
COMPUTE HRUSL2=995
ELSE IF (Q5_28B EQ 1)
COMPUTE HRUSL2=Q5_28C
ELSE IF (Q5_28D EQ 1)
COMPUTE HRUSL2=Q5_28E
ELSE 
COMPUTE HRUSL2=-3
END IF 
 
/* the following lines create the var HRUSLT */
DO IF (Q5B2_25 EQ -4)
COMPUTE HRUSLT=-4
ELSE IF ((Q5B2_26A EQ -1 OR Q5B2_26C EQ -1 OR Q5B2_26A EQ -2 OR 
        Q5B2_26C EQ -2) AND (Q5B2_28B EQ -1 OR Q5B2_28D EQ -1 OR 
        Q5B2_28B EQ -2 OR Q5B2_28D EQ -2))
COMPUTE HRUSLT=-2
ELSE IF ((Q5B2_26A EQ 995 OR Q5B2_26C EQ 995) AND (Q5B2_28B EQ 995 OR 
        Q5B2_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5B2_26A EQ -1 OR Q5B2_26C EQ -1 OR Q5B2_26A EQ -2 OR 
        Q5B2_26C EQ -2) AND (Q5B2_28B EQ 995 OR Q5B2_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5B2_26A EQ 995 OR Q5B2_26C EQ 995) AND
                    (Q5B2_28B EQ -1 OR Q5B2_28D EQ -1 OR Q5B2_28B EQ -2 OR Q5B2_28D EQ -2))
COMPUTE HRUSLT=995
ELSE IF ((Q5B2_26A EQ 995 OR Q5B2_26C EQ 995) AND Q5B2_27 NE 1)
COMPUTE HRUSLT=995
ELSE IF ((Q5B2_26A EQ -1 OR Q5B2_26C EQ -1 OR Q5B2_26A EQ -2 OR 
        Q5B2_26C EQ -2) AND Q5B2_27 NE 1)
COMPUTE HRUSLT=-2
ELSE IF (Q5B2_26A EQ 1 AND (Q5B2_28B EQ -1 OR Q5B2_28B EQ -2 OR 
        Q5B2_28B EQ 995 OR Q5B2_28D EQ -1 OR Q5B2_28D EQ -2 OR 
        Q5B2_28D EQ 995))
COMPUTE HRUSLT=Q5B2_26B
ELSE IF (Q5B2_26C EQ 1 AND (Q5B2_28B EQ -1 OR Q5B2_28B EQ -2 OR 
        Q5B2_28B EQ 995 OR Q5B2_28D EQ -1 OR Q5B2_28D EQ -2 OR Q5B2_28D EQ 995))
COMPUTE HRUSLT=Q5B2_26D
ELSE IF (Q5B2_28B EQ 1 AND (Q5B2_26A EQ -1 OR Q5B2_26A EQ -2 OR 
        Q5B2_26A EQ 995 OR Q5B2_26C EQ -1 OR Q5B2_26C EQ -2 OR Q5B2_26C EQ 995))
COMPUTE HRUSLT=Q5B2_28C
ELSE IF (Q5B2_28D EQ 1 AND (Q5B2_26A EQ -1 OR Q5B2_26A EQ -2 OR 
        Q5B2_26A EQ 995 OR Q5B2_26C EQ -1 OR Q5B2_26C EQ -2 OR Q5B2_26C EQ 995))
COMPUTE HRUSLT=Q5B2_28E
ELSE IF (Q5B2_26A EQ 1 AND Q5B2_27 NE 1)
COMPUTE HRUSLT=Q5B2_26B
ELSE IF (Q5B2_26C EQ 1 AND Q5B2_27 NE 1)
COMPUTE HRUSLT=Q5B2_26D
ELSE IF (Q5B2_26A EQ 1 AND Q5B2_28B EQ 1)
COMPUTE HRUSLT=Q5B2_26B+Q5B2_28C
ELSE IF (Q5B2_26A EQ 1 AND Q5B2_28D EQ 1)
COMPUTE HRUSLT=Q5B2_26B+Q5B2_28E
ELSE IF (Q5B2_26C EQ 1 AND Q5B2_28B EQ 1)
COMPUTE HRUSLT=Q5B2_26D+Q5B2_28C
ELSE IF (Q5B2_26C EQ 1 AND Q5B2_28D EQ 1)
COMPUTE HRUSLT=Q5B2_26C+Q5B2_28E
 
ELSE IF (Q5B_25 EQ -4)
COMPUTE HRUSLT=-4
ELSE IF ((Q5B_26A EQ -1 OR Q5B_26C EQ -1 OR Q5B_26A EQ -2 OR 
        Q5B_26C EQ -2) AND (Q5B_28B EQ -1 OR Q5B_28D EQ -1 OR 
        Q5B_28B EQ -2 OR Q5B_28D EQ -2))
COMPUTE HRUSLT=-2
ELSE IF ((Q5B_26A EQ 995 OR Q5B_26C EQ 995) AND (Q5B_28B EQ 995 OR 
        Q5B_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ -1 OR Q5B_26C EQ -1 OR Q5B_26A EQ -2 OR 
        Q5B_26C EQ -2) AND (Q5B_28B EQ 995 OR Q5B_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ 995 OR Q5B_26C EQ 995) AND
                    (Q5B_28B EQ -1 OR Q5B_28D EQ -1 OR Q5B_28B EQ -2 OR Q5B_28D EQ -2))
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ 995 OR Q5B_26C EQ 995) AND Q5B_27 NE 1)
COMPUTE HRUSLT=995
ELSE IF ((Q5B_26A EQ -1 OR Q5B_26C EQ -1 OR Q5B_26A EQ -2 OR 
        Q5B_26C EQ -2) AND Q5B_27 NE 1)
COMPUTE HRUSLT=-2
ELSE IF (Q5B_26A EQ 1 AND (Q5B_28B EQ -1 OR Q5B_28B EQ -2 OR 
        Q5B_28B EQ 995 OR Q5B_28D EQ -1 OR Q5B_28D EQ -2 OR 
        Q5B_28D EQ 995))
COMPUTE HRUSLT=Q5B_26B
ELSE IF (Q5B_26C EQ 1 AND (Q5B_28B EQ -1 OR Q5B_28B EQ -2 OR 
        Q5B_28B EQ 995 OR Q5B_28D EQ -1 OR Q5B_28D EQ -2 OR Q5B_28D EQ 995))
COMPUTE HRUSLT=Q5B_26D
ELSE IF (Q5B_28B EQ 1 AND (Q5B_26A EQ -1 OR Q5B_26A EQ -2 OR 
        Q5B_26A EQ 995 OR Q5B_26C EQ -1 OR Q5B_26C EQ -2 OR Q5B_26C EQ 995))
COMPUTE HRUSLT=Q5B_28C
ELSE IF (Q5B_28D EQ 1 AND (Q5B_26A EQ -1 OR Q5B_26A EQ -2 OR 
        Q5B_26A EQ 995 OR Q5B_26C EQ -1 OR Q5B_26C EQ -2 OR Q5B_26C EQ 995))
COMPUTE HRUSLT=Q5B_28E
ELSE IF (Q5B_26A EQ 1 AND Q5B_27 NE 1)
COMPUTE HRUSLT=Q5B_26B
ELSE IF (Q5B_26C EQ 1 AND Q5B_27 NE 1)
COMPUTE HRUSLT=Q5B_26D
ELSE IF (Q5B_26A EQ 1 AND Q5B_28B EQ 1)
COMPUTE HRUSLT=Q5B_26B+Q5B_28C
ELSE IF (Q5B_26A EQ 1 AND Q5B_28D EQ 1)
COMPUTE HRUSLT=Q5B_26B+Q5B_28E
ELSE IF (Q5B_26C EQ 1 AND Q5B_28B EQ 1)
COMPUTE HRUSLT=Q5B_26D+Q5B_28C
ELSE IF (Q5B_26C EQ 1 AND Q5B_28D EQ 1)
COMPUTE HRUSLT=Q5B_26C+Q5B_28E
 
ELSE IF (Q5_25 EQ -4)
COMPUTE HRUSLT=-4
ELSE IF ((Q5_26A EQ -1 OR Q5_26C EQ -1 OR Q5_26A EQ -2 OR Q5_26C EQ -2) AND
                    (Q5_28B EQ -1 OR Q5_28D EQ -1 OR Q5_28B EQ -2 OR Q5_28D EQ -2))
COMPUTE HRUSLT=-2
ELSE IF ((Q5_26A EQ 995 OR Q5_26C EQ 995) AND (Q5_28B EQ 995 OR Q5_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5_26A EQ -1 OR Q5_26C EQ -1 OR Q5_26A EQ -2 OR Q5_26C EQ -2) AND
                    (Q5_28B EQ 995 OR Q5_28D EQ 995))
COMPUTE HRUSLT=995
ELSE IF ((Q5_26A EQ 995 OR Q5_26C EQ 995) AND
                    (Q5_28B EQ -1 OR Q5_28D EQ -1 OR Q5_28B EQ -2 OR Q5_28D EQ -2))
COMPUTE HRUSLT=995
ELSE IF ((Q5_26A EQ 995 OR Q5_26C EQ 995) AND Q5_27 NE 1)
COMPUTE HRUSLT=995
ELSE IF ((Q5_26A EQ -1 OR Q5_26C EQ -1 OR Q5_26A EQ -2 OR Q5_26C EQ -2) AND 
                    Q5_27 NE 1)
COMPUTE HRUSLT=-2
ELSE IF (Q5_26A EQ 1 AND (Q5_28B EQ -1 OR Q5_28B EQ -2 OR Q5_28B EQ 995 OR
                    Q5_28D EQ -1 OR Q5_28D EQ -2 OR Q5_28D EQ 995))
COMPUTE HRUSLT=Q5_26B
ELSE IF (Q5_26C EQ 1 AND (Q5_28B EQ -1 OR Q5_28B EQ -2 OR Q5_28B EQ 995 OR
                    Q5_28D EQ -1 OR Q5_28D EQ -2 OR Q5_28D EQ 995))
COMPUTE HRUSLT=Q5_26D
ELSE IF (Q5_28B EQ 1 AND (Q5_26A EQ -1 OR Q5_26A EQ -2 OR Q5_26A EQ 995 OR
                    Q5_26C EQ -1 OR Q5_26C EQ -2 OR Q5_26C EQ 995))
COMPUTE HRUSLT=Q5_28C
ELSE IF (Q5_28D EQ 1 AND (Q5_26A EQ -1 OR Q5_26A EQ -2 OR Q5_26A EQ 995 OR
                    Q5_26C EQ -1 OR Q5_26C EQ -2 OR Q5_26C EQ 995))
COMPUTE HRUSLT=Q5_28E
ELSE IF (Q5_26A EQ 1 AND Q5_27 NE 1)
COMPUTE HRUSLT=Q5_26B
ELSE IF (Q5_26C EQ 1 AND Q5_27 NE 1)
COMPUTE HRUSLT=Q5_26D
ELSE IF (Q5_26A EQ 1 AND Q5_28B EQ 1)
COMPUTE HRUSLT=Q5_26B+Q5_28C
ELSE IF (Q5_26A EQ 1 AND Q5_28D EQ 1)
COMPUTE HRUSLT=Q5_26B+Q5_28E
ELSE IF (Q5_26C EQ 1 AND Q5_28B EQ 1)
COMPUTE HRUSLT=Q5_26D+Q5_28C
ELSE IF (Q5_26C EQ 1 AND Q5_28D EQ 1)
COMPUTE HRUSLT=Q5_26C+Q5_28E
ELSE 
COMPUTE HRUSLT=-3
END IF
 
/* the following lines create the var HRFTPT */
DO IF (Q5B2_30C EQ -4)
COMPUTE HRFTPT=-4
ELSE IF (Q5B2_30F EQ -1 OR Q5B2_30G EQ -1 OR Q5B2_30H EQ -1 OR Q5B2_30I EQ -1)
COMPUTE HRFTPT=-1
ELSE IF (Q5B2_30F EQ -2 OR Q5B2_30G EQ -2 OR Q5B2_30H EQ -2 OR Q5B2_30I EQ -2)
COMPUTE HRFTPT=-2
ELSE IF (Q5B2_30F NE -4)
COMPUTE HRFTPT=Q5B2_30F
ELSE IF (Q5B2_30G NE -4)
COMPUTE HRFTPT=Q5B2_30G
ELSE IF (Q5B2_30H NE -4)
COMPUTE HRFTPT=Q5B2_30H
ELSE IF (Q5B2_30I NE -4)
COMPUTE HRFTPT=Q5B2_30I
 
ELSE IF (Q5B_30C EQ -4)
COMPUTE HRFTPT=-4
ELSE IF (Q5B_30F EQ -1 OR Q5B_30G EQ -1 OR Q5B_30H EQ -1 OR Q5B_30I EQ -1)
COMPUTE HRFTPT=-1
ELSE IF (Q5B_30F EQ -2 OR Q5B_30G EQ -2 OR Q5B_30H EQ -2 OR Q5B_30I EQ -2)
COMPUTE HRFTPT=-2
ELSE IF (Q5B_30F NE -4)
COMPUTE HRFTPT=Q5B_30F
ELSE IF (Q5B_30G NE -4)
COMPUTE HRFTPT=Q5B_30G
ELSE IF (Q5B_30H NE -4)
COMPUTE HRFTPT=Q5B_30H
ELSE IF (Q5B_30I NE -4)
COMPUTE HRFTPT=Q5B_30I
 
ELSE IF (Q5_30C EQ -4)
COMPUTE HRFTPT=-4
ELSE IF (Q5_30F EQ -1 OR Q5_30G EQ -1 OR Q5_30H EQ -1 OR Q5_30I EQ -1)
COMPUTE HRFTPT=-1
ELSE IF (Q5_30F EQ -2 OR Q5_30G EQ -2 OR Q5_30H EQ -2 OR Q5_30I EQ -2)
COMPUTE HRFTPT=-2
ELSE IF (Q5_30F NE -4)
COMPUTE HRFTPT=Q5_30F
ELSE IF (Q5_30G NE -4)
COMPUTE HRFTPT=Q5_30G
ELSE IF (Q5_30H NE -4)
COMPUTE HRFTPT=Q5_30H
ELSE IF (Q5_30I NE -4)
COMPUTE HRFTPT=Q5_30I
ELSE
COMPUTE HRFTPT=-3
END IF 
 
/* the following lines create the var HRWANT */
DO IF (Q5B2_33 NE -4)
COMPUTE HRWANT=Q5B2_33
ELSE IF (Q5B_33 NE -4)
COMPUTE HRWANT=Q5B_33
ELSE 
COMPUTE HRWANT=Q5_33
END IF
 
/* the following lines create the var HRRSN1 */
DO IF (Q5B2_34 NE -4)
COMPUTE HRRSN1=Q5B2_34
ELSE IF (Q5B_34 NE -4)
COMPUTE HRRSN1=Q5B_34
ELSE
COMPUTE HRRSN1=Q5_34
END IF
 
/* the following lines create the var HRCK7 */
COMPUTE HRCK7=-4
DO IF ((BUS2 EQ 2 OR BUS2 EQ -2 OR BUS2 EQ -1) AND (HRACT1 LT 15 
                    OR HRACT1 EQ -2))
COMPUTE HRCK7=1
ELSE IF ((BUS2 EQ 2 OR BUS2 EQ -2 OR BUS2 EQ -1) AND HRACT1 GE 15)
COMPUTE HRCK7=2
ELSE IF ((HRUSLT GE 35 OR HRFTPT EQ 1) AND HRACTT LT 35 AND (HRACT1 NE -1
                    OR HRACT1 NE -2 OR HRACT2 NE -1 OR HRACT2 NE -2)) 
COMPUTE HRCK7=3
ELSE IF (HRWANT EQ 1 AND HRACTT LT 35 AND (HRRSN1 EQ 1 OR HRRSN1 EQ 2
                    OR HRRSN1 EQ 3))
COMPUTE HRCK7=4
ELSE 
COMPUTE HRCK7=5
END IF 
 
/* the following lines create the var ABSOT */
DO IF (HRACT1 EQ 0 AND HRACT2 EQ 0)
COMPUTE ABSOT=1
ELSE
COMPUTE ABSOT=0
END IF
 
/* the following lines create the var HRCK6 */
COMPUTE HRCK6=-4
DO IF ((HRACT1 EQ 0 AND HRACT2 EQ 0) AND (BUS2 EQ 2 OR BUS2 EQ -1 
                    OR BUS2 EQ -2))
COMPUTE HRCK6=1
ELSE IF (ABSOT EQ 1)
COMPUTE HRCK6=2
ELSE 
COMPUTE HRCK6=3
END IF
 
/* the following lines create the var WK */
COMPUTE WK=-4
DO IF (Q5_2 NE -4)
COMPUTE WK=Q5_2
ELSE IF (Q5_3 NE -4)
COMPUTE WK=Q5_3
END IF
 
/* the following lines create the var RETOT */
DO IF (WK EQ 2)
COMPUTE RETOT=1
ELSE
COMPUTE RETOT=0
END IF
 
/* the following lines rename the vars */
COMPUTE BUS1=Q5_5
COMPUTE RET1=Q5_10
COMPUTE IO1COW=Q5_JUMP
COMPUTE NLFACT=Q5_93
 
/* the following lines create additional variables */
DO IF (Q5B2_22 NE -4)
COMPUTE ABSPD=Q5B2_22
ELSE IF (Q5B_22 NE -4)
COMPUTE ABSPD=Q5B_22
ELSE
COMPUTE ABSPD=Q5_22
END IF
 
DO IF (Q5B2_65 NE -4)
COMPUTE LKAVL=Q5B2_65
ELSE IF (Q5B_65 NE -4)
COMPUTE LKAVL=Q5B_65
ELSE
COMPUTE LKAVL=Q5_65
END IF
 
DO IF (Q5B2_51 NE -4)
COMPUTE LAYAVL=Q5B2_51
ELSE IF (Q5B_51 NE -4)
COMPUTE LAYAVL=Q5B_51
ELSE
COMPUTE LAYAVL=Q5_51
END IF
 
DO IF (Q5B2_66 NE -4)
COMPUTE LKAVR=Q5B2_66
ELSE IF (Q5B_66 NE -4)
COMPUTE LKAVR=Q5B_66
ELSE
COMPUTE LKAVR=Q5_66
END IF
 
DO IF (Q5B2_52 NE -4)
COMPUTE LAYAVR=Q5B2_52
ELSE IF (Q5B_52 NE -4)
COMPUTE LAYAVR=Q5B_52
ELSE
COMPUTE LAYAVR=Q5_52
END IF
 
DO IF (Q5B2_60 NE -4)
COMPUTE LK=Q5B2_60
ELSE IF (Q5B_60 NE -4)
COMPUTE LK=Q5B_60
ELSE
COMPUTE LK=Q5_60
END IF
 
DO IF (Q5B2_11 NE -4)
COMPUTE DIS1=Q5B2_11
ELSE IF (Q5B_11 NE -4)
COMPUTE DIS1=Q5B_11
ELSE
COMPUTE DIS1=Q5_11
END IF
 
DO IF (Q5B2_12 NE -4)
COMPUTE DIS2=Q5B2_12
ELSE IF (Q5B_12 NE -4)
COMPUTE DIS2=Q5B_12
ELSE
COMPUTE DIS2=Q5_12
END IF
 
/* the following lines create the var DWWNTO */
DO IF (RET1 EQ 1)
COMPUTE DWWNTO=1
 
ELSE IF (Q5B2_78 EQ 1)
COMPUTE DWWNTO=1
ELSE IF (Q5B2_78 EQ 0)
COMPUTE DWWNTO=2
ELSE IF (Q5B2_78 EQ -2)
COMPUTE DWWNTO=-2
ELSE IF (Q5B2_78 EQ -1)
COMPUTE DWWNTO=-1
ELSE IF (Q5B2_78 EQ 3)
COMPUTE DWWNTO=3
ELSE IF (Q5B2_78 EQ 4)
COMPUTE DWWNTO=4
ELSE IF (Q5B_78 EQ 1)
COMPUTE DWWNTO=1
ELSE IF (Q5B_78 EQ 0)
COMPUTE DWWNTO=2
ELSE IF (Q5B_78 EQ -2)
COMPUTE DWWNTO=-2
ELSE IF (Q5B_78 EQ -1)
COMPUTE DWWNTO=-1
ELSE IF (Q5B_78 EQ 3)
COMPUTE DWWNTO=3
ELSE IF (Q5B_78 EQ 4)
COMPUTE DWWNTO=4
ELSE IF (Q5_78 EQ 1)
COMPUTE DWWNTO=1
ELSE IF (Q5_78 EQ 0)
COMPUTE DWWNTO=2
ELSE IF (Q5_78 EQ -2)
COMPUTE DWWNTO=-2
ELSE IF (Q5_78 EQ -1)
COMPUTE DWWNTO=-1
ELSE IF (Q5_78 EQ 3)
COMPUTE DWWNTO=3
ELSE IF (Q5_78 EQ 4)
COMPUTE DWWNTO=4
ELSE
COMPUTE DWWNTO=-3
END IF
 
/* the following lines create the var DIS */
DO IF (Q5_9A4 EQ -4)
COMPUTE DIS=-4
ELSE IF (Q5_9D EQ -1 OR Q5_9E EQ -1 OR Q5_9F EQ -1 OR Q5_9G EQ -1)
                    OR (Q5_9D EQ -2 OR Q5_9E EQ -2 OR Q5_9F EQ -2 OR Q5_9G EQ -2)
COMPUTE DIS=-2
ELSE IF (Q5_9A4 EQ 1 AND Q5_9D EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9D EQ 0)
COMPUTE DIS=0
ELSE IF (Q5_9A5 EQ 1 AND Q5_9E EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9E EQ 0)
COMPUTE DIS=0
ELSE IF (Q5_9A6 EQ 1 AND Q5_9F EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9F EQ 0)
COMPUTE DIS=0
ELSE IF (Q5_9A7 EQ 1 AND Q5_9G EQ 1)
COMPUTE DIS=1
ELSE IF (Q5_9G EQ 0)
COMPUTE DIS=0
ELSE 
COMPUTE DIS=-3
END IF
 
/* the following lines create IO1COW */
DO IF (Q5_JUMP EQ 1)
COMPUTE IO1COW=8
ELSE
COMPUTE IO1COW=0
END IF
 
/* the following lines create the ESR var approximating MLR */
DO IF ((WK EQ 1 AND (HRCK6 EQ 3 OR HRCK6 EQ -4 OR HRCK6 EQ 99 OR 
        HRCK6 EQ 999)) OR 
       (BUS1 EQ 1 AND (HRCK7 EQ 2 OR HRCK7 EQ 3 OR HRCK7 EQ 4 OR 
        HRCK7 EQ 5 OR HRCK7 EQ -4)))
COMPUTE ESR=1
ELSE IF (ABSPD EQ 1 OR ABSPD EQ 0 OR ABSPD EQ -1 OR ABSPD EQ -2)
COMPUTE ESR=2
ELSE IF ((LAYAVL EQ 1 OR LAYAVL EQ -1 OR LAYAVL EQ -2) OR LAYAVR EQ 1)
COMPUTE ESR=3
ELSE IF ((LKAVL EQ 1 OR LKAVL EQ -1 OR LKAVL EQ -2) OR (LKAVR EQ 1 OR 
                    LKAVR EQ 2))
COMPUTE ESR=4
ELSE IF ((WK EQ 3 AND AGE GE 50 AND RET1 EQ 1 AND LK EQ 1 AND LKAVL EQ 0 AND
                    (LKAVR EQ 3 OR LKAVR EQ 4 OR LKAVR EQ -1 OR LKAVR EQ -2)) OR
                    (RET1 EQ 0 OR LK EQ 3 OR DWWNTO EQ 3) OR NLFACT EQ 5 OR RETOT EQ 1) 
COMPUTE ESR=5
ELSE IF (DIS1 EQ 1 OR DIS2 EQ 1 OR DIS EQ 1)
COMPUTE ESR=6
ELSE IF (Q5_JUMP EQ 1)
COMPUTE ESR=8
/* ELSE IF (IO1COW EQ 8) */
/* COMPUTE ESR=7 */
ELSE
COMPUTE ESR=7
END IF 

/*COLLAPSED EMPLOYMENT STATUS RECODE 1998*/

DO IF (ESR = -5)
COMPUTE ESRC=-5
ELSE IF (ESR = 1 OR ESR = 2)
COMPUTE ESRC=1
ELSE IF (ESR = 3 OR ESR = 4)
COMPUTE ESRC=2
ELSE IF (ESR >= 4 AND ESR <= 7)
COMPUTE ESRC=3
ELSE 
COMPUTE ESRC=ESR
END IF
 
IF (Q5_JUMP = 1) ESRC=4

 

2006 SAS CODE

/*this section computes hract1, hract2, & hractt*/
hract1=-4;

array q540a (i) Q5_40A_02 Q5_40A_01;*WAS Q5-36 ANSWERED:DID RESPONDENT LOSE OR TAKE OFF HOURS LAST WEEK?;
array q540b (i) Q5_40B_02 Q5_40B_01;*R ANSWERED Q5-36 AND DID HAVE MORE THAN ONE JOB/BUSINESS LAST WEEK.;
array q540c (i) Q5_40C_02 Q5_40C_01;*R DID NOT ANSWER Q5-36 AND DID HAVE MORE THAN ONE JOB/BUSINESS LAST WEEK.;
array q540d (i) Q5_40D_02 Q5_40D_01;*R ANSWERED Q5-36 BUT DID NOT HAVE MORE THAN ONE JOB/BUSINESS LAST WEEK;
array q540e (i) Q5_40E_02 Q5_40E_01;*R DID NOT ANSWER Q5-36 AND DID NOT HAVE MORE THAN ONE JOB/BUSINESS LAST WEEK;
array q541a (i) Q5_41A_02 Q5_41A_01;*NUMBER OF HOURS R ACTUALLY WORKED AT MAIN JOB LAST WEEK;
array q541b (i) Q5_41B_02 Q5_41B_01;*NUMBER OF HOURS R ACTUALLY WORKED AT MAIN JOB LAST WEEK;
array q541c (i) Q5_41C_02 Q5_41C_01;*NUMBER OF HOURS R ACTUALLY WORKED AT JOB LAST WEEK;
array q541d (i) Q5_41D_02 Q5_41D_01;*NUMBER OF HOURS R ACTUALLY WORKED AT JOB LAST WEEK;

do i=1 to 2;
if hract1=-4 then do;
if missing(q540a) then hract1=-4;
else if ((q541a=-1 | q541b=-1 | q541c=-1 | q541d=-1) |
(q541a=-2 | q541b=-2 | q541c=-2 | q541d=-2)) then hract1=-2;
else if (q540b=1 & not missing(q541a)) then hract1= q541a;
else if (q540c=1 & not missing(q541b)) then hract1= q541b;
else if (q540d=1 & not missing(q541c)) then hract1= q541c;
else if (q540e=1 | q540e=0) then hract1= q541d;
end;
end;

hract2=-4;
array q542 (i) Q5_42_02 Q5_42_01;*DOES R HAVE MORE THAN ONE JOB?;
array q543 (i) Q5_43_02 Q5_43_01;*RESPONDENT HAS AT LEAST 3 JOBS;
array q543b (i) Q5_43B_02 Q5_43B_01;*NUMBER OF HOURS RESPONDENT ACTUALLY WORKED AT OTHER JOB LAST WEEK;

do i=1 to 2;
if hract2=-4 then do;
if (missing(q542)| q542=0) then hract2=-4;
else if (q543b=-1 | q543b=-2) then hract2=-2;
else if (q543=1) then hract2=q543b;*How about if q542=1???, line 93;
end;
end;

hractt=-4;
do i=1 to 2;
if hractt=-4 then do;
if missing(q540a) then hractt=-4;
else if ((hract1=-2) & (hract2=-2) | (missing(q543b))) then hractt=-2;
else if (hract1=-2 | hract2=-2) then hractt=995;
else if q543b=-4 then hractt=995;
else if ((q541a>0 & q541a~=995) & ((hract2=-2 | hract2=995)|missing(q543b)))
then hractt=q541a;
else if ((q541b>0 & q541b~=995) & ((hract2=-2 | hract2=995)|missing(q543b)))
then hractt=q541b;
else if ((q541c>0 & q541c~=995) & ((hract2=-2 | hract2=995)|missing(q543b)))
then hractt=q541c;
else if ((q541d>0 & q541d~=995) & ((hract2=-2 | hract2=995)|missing(q543b)))
then hractt=q541d;
else if ((q543b>0 & q543b~=995) & (hract1=-2 | hract1=995))
then hractt=q543b;
else if (q541a>0 & q541a~=995) then hractt=q541a;*total hours worked,last week;
else if ((q541a>0 & q541a~=995) & (q543b>0 & q543b~=995)) then hractt=q541a + q543b;
else if (q541b>0 & q541b~=995) then hractt=q541b;
else if ((q541b>0 & q541b~=995) & (q543b>0 & q543b~=995)) then hractt=q541b + q543b;
else if (q541c>0 & q541c~=995) then hractt=q541c;
else if ((q541c>0 & q541c~=995) & (q543b>0 & q543b~=995)) then hractt=q541c + q543b;
else if (q541a>0 & q541d~=995)then hractt=q541d;
else if ((q541a>0 & q541d~=995) & (q543b>0 & q543b~=995)) then hractt=q541d + q543b;
else hractt=-3;
end;
end;

/*business variables*/

bus2=0;

if missing(Q5_6) then bus2=-4; *DOES R OWN BUSINESS OR FARM?;
else if (Q5_6=-1 | Q5_8=-1) then bus2=-1;*NO Q5-7;
else if (Q5_6=-2 | Q5_8=-2) then bus2=-2;
else if (Q5_8=1) then bus2=1;*Q5-8: DOES R RECEIVES INCOME BUSINESS OR FARM (R DOES NOT OWN BUSINESS/FARM);
else if Q5_8=0 then bus2=0;
else bus2=-3;

/*set hours worked variables*/
hrusl1=-4;
array q525 (i) Q5_25_02 Q5_25_01;*R REPORTS MORE THAN ONE JOB OR BUSINESS;
array q526a (i) Q5_26A_02 Q5_26A_01;*NUMBER OF HOURS RESPONDENT USUALLY WORKS AT MAIN JOB;
array q526b (i) Q5_26B_02 Q5_26B_01;*NUMBER OF HOURS R USUALLY WORKS AT MAIN JOB;
array q526c (i) Q5_26C_02 Q5_26C_01;*NUMBER OF HOURS PER WEEK RESPONDENT USUALLY WORKS AT JOB;
array q526d (i) Q5_26D_02 Q5_26D_01;*NUMBER OF HOURS PER WEEK RESPONDENT USUALLY WORKS AT JOB;

do i=1 to 2;
if hrusl1=-4 then do;
if missing(q525) then hrusl=-4;
else if (q526a=-1 | q526c=-1 | q526a=-2 | q526c=-2)
then hrusl1=-2;
else if (q526a=995 | q526c=995) then hrusl1=995;
else if q526a=1 then hrusl1=q526b;
else if q526c=1 then hrusl1=q526d;
end;
end;

hrusl2=-4;
array q528a (i) Q5_28A_02 Q5_28A_01;*R REPORTS AT LEAST 3 OTHER JOBS;
array q528b (i) Q5_28B_02 Q5_28B_01;*NUMBER OF HOURS PER WEEK RESPONDENT USUALLY WORKS AT OTHER JOB;
array q528c (i) Q5_28C_02 Q5_28C_01;*NUMBER OF HOURS R USUALLY WORKS AT OTHER JOB;
array q528d (i) Q5_28D_02 Q5_28D_01;*NUMBER OF HOURS PER WEEK RESPONDENT USUALLY WORKS AT OTHER JOBS;
array q528e (i) Q5_28E_02 Q5_28E_01;*NUMBER OF HOURS PER WEEK R USUALLY WORKS AT OTHER JOBS;

do i= 1 to 2;
if hrusl2=-4 then do;
if missing(q528a) then hrusl2=-4;
else if (q528b=-1| q528d=-1 | q528b=-2 | q528d=-2) then hrusl2=-2;
else if (q528b=1) then hrusl2=q528c;
else if (q528d=1) then hrusl2=q528e;
else hrusl2=-3;
end;
end;

hruslt=-4;
array q527 (i) Q5_27_02 Q5_27_01;*R REPORTS MORE THAN ONE JOB;

do i=1 to 2;
if hruslt=-4 then do;
if missing(q525) then hruslt=-4;
else if ((hrusl1=-2 & hrusl2=-2) | (hrusl1=-2 & q527~=1)) then hruslt=-2;
else if ((hrusl1=995 & hrusl2=995) | (hrusl1=-2 & hrusl2=995) |
(hrusl1=995 & hrusl2=-2) | (hrusl1=-2 & q527~=1)) then hurslt=995;
else if (hrusl1=q526b & (hrusl2=-2 | hrusl2=995)) then hruslt= hrusl1;
else if (hrusl1=q526d & (hrusl2=-2 | hrusl2=995)) then hruslt= hrusl1;
else if (q528b=1 & (hrusl1=-2 | hrusl1=995)) then hruslt= hrusl2;
else if (q528d=1 & (hrusl1=-2 | hrusl1=995)) then hruslt= hrusl2;
else if (q526a=1 & q527~=1) then hruslt=q526b;
else if (q526c=1 & q527~=1) then hruslt=q526d;
else if (q526a=1 & q528b=1)then hruslt= (q526b + q528c);*total hours worked, usually;
else if (q526a=1 & q528d=1)then hruslt= (q526b + q528e);
else if (q526c=1 & q528b=1)then hruslt= (q526d + q528c);
else if (q526c=1 & q528d=1)then hruslt= (q526d + q528e);
else hruslt=-3;
end;
end;

hrftpt=-4;
array q530c (i) Q5_30C_02 Q5_30C_01;*R HAS MORE THAN ONE JOB AND DID UNPAID WORK FOR FAMILY LAST WEEK;
array q530g (i) Q5_30G_02 Q5_30G_01;*RESPONDENT USUALLY WORKS 35 HOURS OR MORE PER WEEK IN FAMILY BUSINESS OR FARM;
array q530i (i) Q5_30I_02 Q5_30I_01;*DOES R USUALLY WORK 35 HOURS OR MORE PER WEEK AT JOB?;

do i= 1 to 2;
if hrftpt=-4 then do;
if missing(q530c) then hrftpt=-4;
else if (q530g=-1 | q530i=-1) then hrftpt=-1;
else if (q530g=-2 | q530i=-2) then hrftpt=-2;
else if not missing(q530g) then hrftpt=q530g;
else if not missing(q530i) then hrftpt=q530i;
else hrftpt=-3;
end;
end;

hrwant=-4;
hrwant=Q5_33_01; *DOES RESPONDENT WANT TO WORK FULL TIME?;

hrrsn1=-4;
hrrsn1=Q5_34_01; *MAIN REASON RESPONDENT WORKS PART-TIME;

hrck7=-4;
if ((bus2=-2 | bus2=-1) & (hract1<15 | hract1=-2)) then hrck7=1;*bus2=2???;
else if ((bus2=-2 | bus2=-1) & (hract1>15)) then hrck7=2;
else if ((hruslt>35 or hrftpt=1) & (hractt<35) & (hract1~=-2 | hract2~=-2)) then hrck7=2;
else if ((hrwant=1) & (hractt<35) & (hrrsn1=1 | hrrsn1=2 | hrrsn1=3)) then hrck7=4;
else hrck7=5;

absot=0;
if (hract1=0 & hract2=0) then absot=1;

hrck6=-4;
if ((hract1=0 & hract2=0) & (bus2=-2 | bus2=-1)) then hrck6=1;
else if absot=1 then hrck6=2;
else hrck6=3;

wk=-4;
if not missing(Q5_2) then wk=Q5_2;*R DO ANY WORK FOR PAY LAST WEEK? (R DOES NOT OWN BUS/FARM);
else if not missing(Q5_3) then wk=Q5_3;*R DO ANY WORK LAST WEEK FOR PAY/PROFIT?;

retot=0;
if wk=2 then retot=1;

bus1=Q5_5;*R DO ANY UNPAID WORK IN FAMILY BUSINESS OR FARM LAST WEEK?;
ret1=Q5_10;*DOES R CURRENTLY WANT A JOB (FULL OR PART TIME)? ;
io1cow=Q5_JUMP;*IS R IN ACTIVE MILITARY?;
nlfact=Q5_93;*BEST DESCRIPTION OF RESPONDENT JOB SITUATION;

/*set out of work variables*/
abspd=-4;
if not missing(Q5_22_02) then abspd=Q5_22_02;*IS RESPONDENT BEING PAID BY EMPLOYER FOR TIME OFF LAST WEEK;
else if not missing(Q5_22_01) then abspd=Q5_22_01;*IS RESPONDENT BEING PAID BY EMPLOYER FOR TIME OFF LAST WEEK;

lkavl=-4;
if not missing(Q5_65_02) then lkavl=Q5_65_02;*COULD R HAVE STARTED A JOB LAST WEEK;
else if not missing(Q5_65_01) then lkavl=Q5_65_01;*COULD R HAVE STARTED A JOB LAST WEEK;

layavl=-4;
if not missing(Q5_51_02) then layavl=Q5_51_02;*COULD R HAVE RETURNED TO WORK LAST WEEK IF CALLED?;
else if not missing(Q5_51_01) then layavl=Q5_51_01;*COULD R HAVE RETURNED TO WORK LAST WEEK IF CALLED?;

lkavr=-4;
if not missing(Q5_66_02) then lkavr=Q5_66_02;*REASON FOR NOT BEING ABLE TO TAKE A JOB LAST WEEK;
else if not missing(Q5_66_01) then lkavr=Q5_66_01;*REASON FOR NOT BEING ABLE TO TAKE A JOB LAST WEEK;

layavr=-4;
if not missing(Q5_52_01) then layavr=Q5_52_01;*REASON FOR NOT BEING ABLE TO WORK LAST WEEK IF CALLED;

lk=-4;
if not missing(Q5_60_02) then lk=Q5_60_02;
else if not missing(Q5_60_01) then lk=Q5_60_01;*HAS R DONE ANYTHING TO FIND WORK DURING THE LAST 4 WEEKS;

dis1=-4;
if not missing(Q5_11_02) then dis1=Q5_11_02;*could not find the question;
else if not missing(Q5_11_01) then dis1=Q5_11_01;*DOES DISABILITY PREVENT R FROM ACCEPTING WORK IN NEXT 6 MONTHS;

dis2=-4;
if not missing(Q5_12_02) then dis2=Q5_12_02;*DOES R HAVE A DISABILITY THAT PREVENT R FROM WORKING IN NEXT 6 MONTHS;
else if not missing(Q5_12_01) then dis2=Q5_12_01; *DOES R HAVE A DISABILITY THAT PREVENT R FROM WORKING IN NEXT 6 MONTHS;

dwwnto=-4;
array q578 (i) Q5_78_02 Q5_78_01;*DOES R CURRENTLY WANT A FULL-TIME OR PART-TIME JOB?;

do i= 1 to 2;
if ret1=1 then dwwnto=1;
else if dwwnto=-4 then do;
if q578=1 then dwwnto=1;
else if q578=0 then dwwnto=2;
else if missing(q578) then dwwnto=-4;
else if q578=-2 then dwwnto=-2;
else if q578=-1 then dwwnto=-1;
else if q578=3 then dwwnto=3;
else if q578=4 then dwwnto=4;
else dwwnto=-3;
end;
end;

io1cow=0;
if Q5_JUMP=1 then io1cow=8;

/* sets esr code*/
esr_key=-4;

if ((wk=1 & (hrck6=3 | hrck6=-4 )) | (bus1=1 AND (hrck7=2 | hrck7=3 | hrck7=4 |
hrck7=5 | hrck7=-4))) then esr_key=1;
else if (abspd=1 | abspd=0 | abspd=-1 | abspd=-2) then esr_key=2;
else if ((layavl=1 | layavl=-1 | layavl=-2) | layavr=1) then esr_key=3;
else if ((lkavl=1 | lkavl=-1 | lkavl=-2) | (lkavr=1 | lkavr=2)) then esr_key=4;
else if ((wk=3 & intage >=50 & ret1=1 & lk=1 & lkavl=0 & (lkavr=3 | lkavr=4 | lkavr=-1 | lkavr=-2)) |
ret1=0 | (lk=3 & intage>=50) | (dwwnto=3 & intage>=50) | nlfact=5 | retot=1) then esr_key=5;
else if (dis1=1 | dis2=1 | (lk=3 & intage<50) | (dwwnto=3 & intage<50)) then esr_key=6;
else if (Q5_JUMP=1) then esr_key=8;*IS R IN ACTIVE MILITARY?;
else if not missing(CURDATE_M) then esr_key=7;
else esr_key=-5;

/*collapsed esr*/
esr_col=0;
if (esr_key=-5) then esr_col=-5;
else if (esr_key=1 | esr_key=2) then esr_col=1;
else if (esr_key=3 | esr_key=4) then esr_col=2;
else if (esr_key>=4 and esr_key<=7) then esr_col=3;
else if Q5_JUMP=1 then esr_col=4;
else esr_col=esr_key;run;