Question 76

You have a dataset 'Customers' with variables 'CustomerlD', 'Age', and 'City'. You want to analyze customer behavior based on age groups, but you only want to include customers from 'New York' and 'Los Angeles'. Which code snippet correctly filters the data and assigns age groups to the customers based on these criteria?
  • Question 77

    You have a SAS dataset called 'CUSTOMERS' with variables: 'CustomerlD', 'Name', 'City', 'State', 'Zip', 'Phone', 'Email'. You want to create a new dataset called 'CUSTOMER INFO' containing only the variables 'Name', 'City', and 'Email', but you also need to remove duplicate records based on the 'CustomerlD' variable. Which code snippet correctly accomplishes this?
  • Question 78

    You are working with a SAS dataset 'PRODUCTS' with variables 'PRODUCT ID', 'PRODUCT NAME', and 'PRICE'. You want to create a new variable 'DISCOUNT PRICE' that calculates a 10% discount on the 'PRICE' if 'PRODUCT NAME' is 'Laptop' and the 'PRICE' is not missing, otherwise set it to missing. Which code snippet correctly achieves this?
  • Question 79

    Which option renames the variable Name to StudentName when reading the ClassRoster data set?
  • Question 80

    You have a SAS dataset named 'SALES DATA' containing sales figures for various products across different regions. You need to determine if the 'PRODUCT ID' variable is a character variable or a numeric variable. What option in PROC CONTENTS would help you identify this?