有一道SAS作业题,怎麼编都做不出最后一张表的结果,求大神帮忙!
Identifying Extreme Valuesin Each Group of Data The data set orion.customer_dim contains informationabout Orion Star customers. Partial orion.customer_dim(77 Total Observations, 11 Total Variables) Customer_ Customer_ID Customer_Name Customer_Type BirthDate 4 James Kvarniq Orion Club members low activity 27JUN1978 5 Sandrina Stephano Orion Club Gold members mediumactivity 09JUL1983 9 Cornelia Krahl Orion Club Gold members mediumactivity 27FEB1978 10 Karen Ballinger Orion Club members high activity 18OCT1988 11 Elke Wallstab Orion Club members high activity 16AUG1978
Use First./Last.processing to create the report below. Show data on the oldest and youngestcustomers for each Customer_Type. · The variable o_ID is the Customer_ID value of the oldest customer and y_ID is the Customer_IDvalue of the youngest customer for each group. · Create a variable named agerange to indicate the spread betweenthese oldest and youngest customers. · Use Customer_BirthDate, rather than Customer_Age, for all age determinations because this is moreaccurate. Partial PROC PRINT Output (7 Total Observations) Oldest and Youngest Customers of eachCustomer Type Customer_Type oldest youngest o_ID y_ID agerange Internet/CatalogCustomers 08JUL1938 18AUG1973 29 54655 35.1 Orion Club members high activity 28SEP1938 24OCT1990 89 46966 52.1 Orion Club members medium activity 20JAN1938 16SEP1992 70059 2806 54.7 Orion Club Goldmembers high activity 16JAN1938 25JUL1988 50 39 50.5 Orion Club Goldmembers low activity 19DEC1973 21JUL1992 70201 13 18.6
! There are several waysto obtain the number of years between two dates. Two possible techniques aredividing days by 365.25 or using the YRDIF function. |