Question: The data set available in the Excel file heart.xlsx is a selected subset of the SASHELP SAS data file heart containing data from the Framingham
The data set available in the Excel file heart.xlsx is a selected subset of the SASHELP SAS data file heart containing data from the Framingham Heart Study. The variables of interest are AgeAtDeath (a numeric variable), DeathCause, and Sex which are character variables. Import the data using proc import and create a SAS data set named heart.
Include statements to create a user-defined numeric format to convert values of age ≤ 29 30 to ≤50, 51 to ≤70, and >71 to character strings
“Under 30,” “30 to 50 years,” “51 to 70 Years,” and “Over 70,” respectively. Use proc sgpanel to obtain a 2×2 panel of bar charts of numbers of deaths due each of four causes of death grouped by sex ( i.e., bars for each value of sex to appear side by side (i.e., clustered)). Note carefully that the formatted variable AgeAtDeath serves as the category variable to be used in proc sgpanel statements.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
