
Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!

For each problem (a & b) you are to create a data step that will read the data and create a temporary SAS data set. Use whatever input style you desire. Use informats, formats, and labels freely. Create a printing (using PROC PRINT) of the data set's variable values making use of titles.
a. Data for ten persons are presented below. Recorded for each person is their age (in years), gender, and survey score. Decide upon a method and format to use in entering the data.
Person 1 2 3 4 5 6 7 8 9 10 Age 26 32 21 23 27 31 29 25 23 21 Gender M M F M F F M F M F Score 1.2 3.4 1.4 2.0 3.3 1.2 2.3 1.8 3.1 2.
b. The data below should be entered as is.
c...:....1....:....2....:....3....:....4....:....5....:....
JOHR Riverside Hospital 23432 ADRS Fairfax/Herndon Memorial Hospital 22411 SMIJ Colfax General Hospital 11234
In the data set above you should produce the following variables:
Variable Name Line Columns IDCODE 1 1- DOB 1 5- GENDER 1 11 HOSPITAL 2 1-? QUES1 3 1 QUES2 3 2 QUES3 3 3 QUES4 3 4 QUES5 3 5
Read Date of Birth with a “Date Informat” (see documentation). The gender data are coded as 1=Male and 2=Female – add labels.
Note: the IDCODE is the “Hogben Code”