If you have a data set that contains 100 variables, but you
need only five of those, what is the code to force SAS to
use only those variable?
Answers were Sorted based on User's Feedback
Answer / sindhura
new_data_set ( will have the five variables with variable
names var1, var2, var3, var4, var5)
data new_data_set;
set old_data_set( keep = var1 var2 var3 var4 var5);
run;
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / mohan reddy
U CAN USE THE KEEP OPTION.
EX
DATA EMP(KEEP=NAME AGE SAL ADD LOC);
SET EMPLOYEE;
RUN;
| Is This Answer Correct ? | 3 Yes | 4 No |
Answer / sandeep reddy
I think we have to use OBS=5
and mention FIRSTOBS=(THE FIRST OBSERVATION FROM WHERE U
WANT)
| Is This Answer Correct ? | 1 Yes | 19 No |
At compile time when a SAS data set is read, what items are created?
What is difference between rename and lable in sas?
what is the use of sas management console? : Sas-di
What is the purpose of the trailing @? The @@? How would you use them?
Where do the database management systems store data and how do u import them.
Describe a time when you were really stuck on a problem and how you solved it?
What statement do you code to write the record to the file?
explain the key concept of sas? : Sas-administrator
In the flow of DATA step processing, what is the first action in a typical DATA Step?
How are the analysis data sets structured?
Describe the ways in which you can create macro variables? : sas-macro
What is the difference between %local and %global?