STAT 506—Homework 2
For most problems you will still need to access the data in the PRG1 folder.
Use the libname statement we learned to
load this each time you work on your assignments. You may now call it ‘orion’ to be consistent with the SAS
materials.
The lecture notes and homeworks will refer to ‘orion’ as the library.
I tried to
bold
the parts where I expect you to actually show me something in your homework solutions if it is not
obvious.
Do the following problems.
1.
Subsetting Observations and Variables Using the WHERE and KEEP Statements
a.
Retrieve and submit the starter program p105e01.
What is the variable name that contains gender values? ________________________________
What are the two possible gender values? ___________________________________________
b.
Add a DATA step before the PROC PRINT step to read the data set
orion.customer_dim
to create a new
data set called
Work.youngadult
.
Show your code for this part.
c.
Modify the PROC PRINT step to refer to the new data set.
Submit the program and confirm that
Work.youngadult
was created with 77 observations and 11 variables.
Show the log for this part.
This
preview
has intentionally blurred sections.
Sign up to view the full version.

This is the end of the preview.
Sign up
to
access the rest of the document.
- Fall '08
- Staff
- Computer program, PROC PRINT
-
Click to edit the document details