Question: Add a proc means step containing appropriate class and output statements, to the same SAS program created in Exercise 2.12, to create a SAS data
Add a proc means step containing appropriate class and output statements, to the same SAS program created in Exercise 2.12, to create a SAS data set named stats1. The data set mystats must contain sample means and standard errors of the means of the variables BMI, RunTime, and Oxygen for each of the nine subgroups defined by combinations of values of the category variables WtGrp and AgeGrp. Use the types statement to ensure that the statistics are calculated only for combinations of levels of WtGrp and AgeGrp. Suppress the printed output produced in the proc means step. Print the data set mystats. Label all new variables on this output.
Exercises 2.14–2.20 concern the demographic data set on countries obtained from Ott et al. (1987) (see Table B.5 of Appendix B). To access this data set from a text file, include an appropriate infile statement in your SAS program. A filename statement may also be included if you prefer. Use the following input statement to read these data:
input Country $20. Birthrat Deathrat Infmort Lifeexp Popurban Percgnp Levtech Civillib;
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
