1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
68
69 DATA LAB.STUDY_COHORT_2;
70 FORMAT race_eth $30.;
71 SET LAB.STUDY_COHORT;
72
73 /* Gestational diabetes */
74 IF RFDiabGest = "True" THEN GestDiab= "Y";
75 ELSE GestDiab= "N";
76
77 /* Race/Ethnicity variable */
78 IF MatRace = " " OR MatEthnicity = " " THEN race_eth=" ";
79 ELSE IF SUBSTR(MatEthnicity,1,1) = "2" THEN race_eth="Hispanic (any race)";
80 ELSE IF SUBSTR(MatRace,2,1)="1" THEN race_eth = "Non-Hispanic White";
81 ELSE race_eth="Non-Hispanic Non-White";
82
83 /* Previous live births need to be converted to numeric variable */
84 prev_alive2 = INPUT(PREV_ALIVE, 2.);
85 IF PREV_ALIVE= . THEN PREV_ALIVE = .;
86
87 /* Convert mother's height to height in inches */
88 IF MotherHeight= . THEN Ht_inches = .;
89 ELSE Ht_inches=(INPUT(SUBSTR(MotherHeight,2,1),1.)*12)+(INPUT(SUBSTR(MotherHeight,4,2),2.));
90
91 /* Convert prior weight to a numeric variable */
92 IF priorweight = . THEN priorweight2 = .; /* Set to missing if unknown */
93 ELSE priorweight2= INPUT(priorweight,4.);
94
95 /* Calculate BMI */
96 IF priorweight2= . or Ht_inches= . THEN BMI = .; /* Set to missing if height or weight is missing */
97 ELSE BMI = ((priorweight2)/(Ht_inches**2))*703;
98
99 /* Categorize into Obese status */
100 IF BMI = . THEN ObesePrior = " "; /* Set to missing if BMI is missing */
101 ELSE IF BMI < 30 THEN ObesePrior = "N";
102 ELSE ObesePrior = "Y";
103
104 /* Variable for preterm birth */
105 IF EstGest > 36 THEN Preterm = "N";
106 ELSE Preterm = "Y";
107
108 /* Labeling new variables */
109 LABEL GestDiab = "Gestational Diabetes"
110 race_eth = "Race/Ethnicity"
111 prev_alive2 = "Previous Live Births"
112 Ht_inches = "Mother's Height (in inches)"
113 priorweight2 = "Prior Weight Before Pregnancy"
114 BMI = "Body Mass Index"
115 ObesePrior = "Obese Prior (Y/N)"
116 Preterm = "Gestation Age Before 37 Weeks";
117 RUN;
NOTE: Character values have been converted to numeric values at the places given by: (Line):(Column).
85:7 88:8 92:8 105:8
NOTE: Numeric values have been converted to character values at the places given by: (Line):(Column).
85:39
NOTE: Invalid numeric data, MotherHeight='05:07' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012000176 MotherHeight=05:07 PriorWeight=170 PREV_ALIVE=2 RFDiabGest= EstGest=39 EstGestOb=
EstGestClin=True Plurality=1 MatEthnicity=210 MatRace=01 M_AGE=31 GestDiab=N prev_alive2=2 Ht_inches=. priorweight2=170 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=1
NOTE: Invalid numeric data, MotherHeight='05:02' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012000324 MotherHeight=05:02 PriorWeight=220 PREV_ALIVE=1 RFDiabGest=True EstGest=38 EstGestOb=True
EstGestClin= Plurality=1 MatEthnicity=280 MatRace=01 M_AGE=32 GestDiab=Y prev_alive2=1 Ht_inches=. priorweight2=220 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=2
NOTE: Invalid numeric data, MotherHeight='05:01' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012000510 MotherHeight=05:01 PriorWeight=123 PREV_ALIVE=0 RFDiabGest= EstGest=39 EstGestOb=True
EstGestClin= Plurality=1 MatEthnicity=210 MatRace=01 M_AGE=20 GestDiab=N prev_alive2=0 Ht_inches=. priorweight2=123 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=3
NOTE: Invalid numeric data, MotherHeight='05:02' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012001165 MotherHeight=05:02 PriorWeight=145 PREV_ALIVE=0 RFDiabGest= EstGest=38 EstGestOb=
EstGestClin=True Plurality=1 MatEthnicity=210 MatRace=01 M_AGE=22 GestDiab=N prev_alive2=0 Ht_inches=. priorweight2=145 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=4
NOTE: Invalid numeric data, MotherHeight='05:04' , at line 88 column 8.
race_eth=Non-Hispanic White ID=2012001472 MotherHeight=05:04 PriorWeight=194 PREV_ALIVE=3 RFDiabGest= EstGest=39 EstGestOb=
EstGestClin=True Plurality=1 MatEthnicity=100 MatRace=01 M_AGE=35 GestDiab=N prev_alive2=3 Ht_inches=. priorweight2=194 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=5
NOTE: Invalid numeric data, MotherHeight='05:07' , at line 88 column 8.
race_eth=Non-Hispanic White ID=2012001710 MotherHeight=05:07 PriorWeight=123 PREV_ALIVE=0 RFDiabGest= EstGest=41 EstGestOb=True
EstGestClin= Plurality=1 MatEthnicity=100 MatRace=01 M_AGE=30 GestDiab=N prev_alive2=0 Ht_inches=. priorweight2=123 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=6
NOTE: Invalid numeric data, MotherHeight='05:04' , at line 88 column 8.
race_eth=Non-Hispanic White ID=2012001836 MotherHeight=05:04 PriorWeight=132 PREV_ALIVE=0 RFDiabGest= EstGest=40 EstGestOb=True
EstGestClin= Plurality=1 MatEthnicity=100 MatRace=01 M_AGE=30 GestDiab=N prev_alive2=0 Ht_inches=. priorweight2=132 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=7
NOTE: Invalid numeric data, MotherHeight='05:03' , at line 88 column 8.
race_eth=Non-Hispanic White ID=2012001863 MotherHeight=05:03 PriorWeight=149 PREV_ALIVE=1 RFDiabGest= EstGest=40 EstGestOb=
EstGestClin=True Plurality=1 MatEthnicity=100 MatRace=01 M_AGE=30 GestDiab=N prev_alive2=1 Ht_inches=. priorweight2=149 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=8
NOTE: Invalid numeric data, MotherHeight='04:08' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012002184 MotherHeight=04:08 PriorWeight=128 PREV_ALIVE=0 RFDiabGest= EstGest=41 EstGestOb=True
EstGestClin= Plurality=1 MatEthnicity=210 MatRace=01 M_AGE=23 GestDiab=N prev_alive2=0 Ht_inches=. priorweight2=128 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=9
NOTE: Invalid numeric data, MotherHeight='05:00' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012002326 MotherHeight=05:00 PriorWeight=160 PREV_ALIVE=0 RFDiabGest= EstGest=37 EstGestOb=True
EstGestClin= Plurality=1 MatEthnicity=281 MatRace=01 M_AGE=20 GestDiab=N prev_alive2=0 Ht_inches=. priorweight2=160 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=10
NOTE: Invalid numeric data, MotherHeight='04:11' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012002393 MotherHeight=04:11 PriorWeight=122 PREV_ALIVE=8 RFDiabGest= EstGest=38 EstGestOb=True
EstGestClin= Plurality=1 MatEthnicity=210 MatRace=01 M_AGE=38 GestDiab=N prev_alive2=8 Ht_inches=. priorweight2=122 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=11
NOTE: Invalid numeric data, MotherHeight='04:11' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012002548 MotherHeight=04:11 PriorWeight=143 PREV_ALIVE=1 RFDiabGest= EstGest=37 EstGestOb=True
EstGestClin= Plurality=1 MatEthnicity=210 MatRace=01 M_AGE=28 GestDiab=N prev_alive2=1 Ht_inches=. priorweight2=143 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=12
NOTE: Invalid numeric data, MotherHeight='05:02' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012003049 MotherHeight=05:02 PriorWeight=125 PREV_ALIVE=1 RFDiabGest= EstGest=41 EstGestOb=
EstGestClin=True Plurality=1 MatEthnicity=210 MatRace=01 M_AGE=20 GestDiab=N prev_alive2=1 Ht_inches=. priorweight2=125 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=13
NOTE: Invalid numeric data, MotherHeight='04:11' , at line 88 column 8.
race_eth=Non-Hispanic White ID=2012003074 MotherHeight=04:11 PriorWeight=195 PREV_ALIVE=1 RFDiabGest= EstGest=35 EstGestOb=True
EstGestClin= Plurality=1 MatEthnicity=100 MatRace=01 M_AGE=28 GestDiab=N prev_alive2=1 Ht_inches=. priorweight2=195 BMI=.
ObesePrior= Preterm=Y _ERROR_=1 _N_=14
NOTE: Invalid numeric data, MotherHeight='05:04' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012003126 MotherHeight=05:04 PriorWeight=160 PREV_ALIVE=1 RFDiabGest= EstGest=40 EstGestOb=
EstGestClin=True Plurality=1 MatEthnicity=210 MatRace=01 M_AGE=23 GestDiab=N prev_alive2=1 Ht_inches=. priorweight2=160 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=15
NOTE: Invalid numeric data, MotherHeight='05:06' , at line 88 column 8.
race_eth=Non-Hispanic White ID=2012003186 MotherHeight=05:06 PriorWeight=130 PREV_ALIVE=0 RFDiabGest= EstGest=39 EstGestOb=
EstGestClin=True Plurality=1 MatEthnicity=100 MatRace=01 M_AGE=30 GestDiab=N prev_alive2=0 Ht_inches=. priorweight2=130 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=16
NOTE: Invalid numeric data, MotherHeight='05:07' , at line 88 column 8.
race_eth=Non-Hispanic White ID=2012003306 MotherHeight=05:07 PriorWeight=137 PREV_ALIVE=0 RFDiabGest= EstGest=37 EstGestOb=True
EstGestClin= Plurality=1 MatEthnicity=100 MatRace=01 M_AGE=21 GestDiab=N prev_alive2=0 Ht_inches=. priorweight2=137 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=17
NOTE: Invalid numeric data, MotherHeight='05:01' , at line 88 column 8.
race_eth=Hispanic (any race) ID=2012003437 MotherHeight=05:01 PriorWeight=130 PREV_ALIVE=0 RFDiabGest= EstGest=39 EstGestOb=
EstGestClin=True Plurality=1 MatEthnicity=281 MatRace=01 M_AGE=16 GestDiab=N prev_alive2=0 Ht_inches=. priorweight2=130 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=18
NOTE: Invalid numeric data, MotherHeight='05:02' , at line 88 column 8.
NOTE: Invalid numeric data, PriorWeight='?' , at line 92 column 8.
race_eth=Non-Hispanic Non-White ID=2012003508 MotherHeight=05:02 PriorWeight=? PREV_ALIVE=3 RFDiabGest= EstGest=39 EstGestOb=
EstGestClin=True Plurality=1 MatEthnicity=100 MatRace=10 M_AGE=24 GestDiab=N prev_alive2=3 Ht_inches=. priorweight2=. BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=19
NOTE: Invalid numeric data, MotherHeight='05:01' , at line 88 column 8.
WARNING: Limit set by ERRORS= option reached. Further errors of this type will not be printed.
race_eth=Non-Hispanic White ID=2012003665 MotherHeight=05:01 PriorWeight=180 PREV_ALIVE=1 RFDiabGest= EstGest=40 EstGestOb=
EstGestClin=True Plurality=1 MatEthnicity=100 MatRace=01 M_AGE=23 GestDiab=N prev_alive2=1 Ht_inches=. priorweight2=180 BMI=.
ObesePrior= Preterm=N _ERROR_=1 _N_=20
NOTE: There were 292 observations read from the data set LAB.STUDY_COHORT.
NOTE: The data set LAB.STUDY_COHORT_2 has 292 observations and 20 variables.
NOTE: DATA statement used (Total process time):
real time 0.01 seconds
user cpu time 0.01 seconds
system cpu time 0.01 seconds
memory 1009.37k
OS Memory 23464.00k
Timestamp 02/28/2024 03:40:49 PM
Step Count 34 Switch Count 2
Page Faults 0
Page Reclaims 173
Page Swaps 0
Voluntary Context Switches 44
Involuntary Context Switches 0
Block Input Operations 32
Block Output Operations 280
118
119 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
129
... View more