112k views
1 vote
If you submit the following program, which variables appear in the new data set?

data falltryout;
set (keep=Month Sport Coach);
if Month="Aug";
drop Month;
run;
a. Month, Sport, Coach
b. Sport, Coach
c. None

User Nofoobar
by
7.7k points

1 Answer

4 votes

Final answer:

The program contains a keep statement for Month, Sport, and Coach, followed by a drop statement for Month. Therefore, only Sport and Coach will appear in the new data set.

Step-by-step explanation:

If you submit the following program, which variables appear in the new data set? The code snippet provided uses SAS data step syntax to manipulate a dataset. There is a keep statement that specifies which variables to keep in the data set, and there is also a drop statement which specifies a variable to be removed.

The keep statement includes the variables Month, Sport, and Coach, but subsequently, the drop statement removes the Month variable. Therefore, the new data set will contain only the Sport and Coach variables.

The answer to the question is b. Sport, Coach.

User Aljgom
by
8.4k points