![]() |
|
Home Statistical
Software What's
New SAS 8.2
|
Statistical Software > SAS II > Self-Assessment Test SAS Workshop Placement Self-Assessment TestDoing the following exercise will help you decide which SAS workshop is appropriate for you. If you have a lot of difficulty doing these tasks, or need a great deal of help to do them, sign up for the SAS I - Introduction class. If you can do these tasks with little or no help, you are ready for the SAS II - Data Management class. The file lowbwt2.dat contains data on 189 subjects. Eight variables were measured on each subject to help identify risk factors associated with giving birth to a baby with low birth weight (weighing <2500 grams). NOTE: These data come from Hosmer and Lemeshow (2000) Applied Logistic Regression: Second Edition. These data are copyrighted by John Wiley & Sons Inc. and must be acknowledged and used accordingly. For purposes of this exercise, a few missing data points have been introduced. First, download the datafile. Click on lowbwt2.dat, then choose Save As on the File menu. The file contains the following information for each subject:
2. Run Proc Freq or Proc Means on each variable, as appropriate. (i.e. choose the appropriate procedure for each variable.) 3. Look at the output and check that all results are reasonable, and that missing values have been handled properly. 4. Save the sas code that you used to do the above steps. 5. Make this a permanent SAS dataset. 6. Exit SAS. 7. In a new SAS session, run Proc Means on the permanent SAS dataset, to compare the mean birth weight of mothers who smoked or didn't smoke. (i.e. run Proc Means on birth weight, using the smoking status variable as a CLASS variable.) 8. Create a new variable "Visits" which is 0 when there were no physician visits during the first trimester, and 1 for 1 or more visits. Make the modified dataset a permanent SAS dataset. 9. Select the subjects who did not visit a physician during the first trimester (Visits=0), and run Proc Means for these subjects, comparing the babies' birthweights for smokers and non-smokers. 10. Repeat using the subjects who did visit a physician during the first trimester (Visits=1). 11. Interpret the results. Are they reasonable?
|