ods pdf file="H:\_ODS\SAS_ACT_09_Output.pdf" notoc; /* SAS Activity #9 */ /* Import student_survey.csv */ /* #1 Create frequency tables for handed and sex */ proc freq data=bio.students; tables handed sex ; run; /* #2 Create summary tables for verbal and age */ proc means data=bio.students mean std min q1 median q3 max maxdec=2 fw=8; var verbal age; run; /* #3 Create simple random sample from entire dataset */ proc surveyselect data=bio.students method=srs n=192 out=bio.students_SRS; run; /* #4 Create frequency tables for handed and sex, summary tables for verbal and age */ proc freq data=bio.students_SRS; tables handed sex ; run; proc means data=bio.students_SRS mean std min q1 median q3 max maxdec=2 fw=8; var verbal age; run; /* #5 Create non-random sample of business students */ data bio.students_bus; set bio.students; if course ne "Business" then delete; run; /* #6 Create frequency tables for handed and sex, summary tables for verbal and age */ proc freq data=bio.students_bus; tables handed sex ; run; proc means data=bio.students_bus mean std min q1 median q3 max maxdec=2 fw=8; var verbal age; run; ods pdf close;