The following SAS program is submitted:
proc means data = sasuser.houses std mean max; var sqfeet run;
Which one of the following is needed to display the standard deviation with only two decimal places?
A. Add the option MAXDEC = 2 to the MEANS procedure statement.
B. Add the statement MAXDEC = 7.2; in the MEANS procedure step.
C. Add the statement FORMAT STD 7.2; in the MEANS procedure step.
D. Add the option FORMAT = 7.2 option to the MEANS procedure statement.
The following SAS SORT procedure step generates an output data set:
proc sort data = sasuser.houses out = report; by style; run;
In which library is the output data set stored?
A. WORK
B. REPORT
C. HOUSES
D. SASUSER
A raw data record is listed below:
----|----10----|----20----|----30
Printing 750
The following SAS program is submitted:
data bonus;
infile `file-specification';
input dept $ 1-11 number 13-15;
run;
Which one of the following SAS statements completes the program and results in a value of `Printing 750' for the DEPARTMENT variable?
A. department = trim(dept) II number;
B. department = dept II input(number,3.);
C. department = trim(dept) II put(number,3.);
D. department = input(dept,11.) II input(number,3.);
The contents of the raw data file PRODUCT are listed below:
----I----10---I----20---I----30
24613 $25.31
The following SAS program is submitted:
data inventory; infile `product; input idnum 5. @10 price; run;
Which one of the following is the value of the PRICE variable?
A. 25.31
B. $25.31
C. . (missing numeric value)
D. No value is stored as the program fails to execute due to errors.
The following SAS program is submitted:
data work.empsalary;
set work.people (in = inemp)
work.money (in = insal):
if insal and inemp;
run;
The SAS data set WORK.PEOPLE has 5 observations, and the data set WORK.MONEY has 7 observations.
How many observations will the data set WORK.EMPSALARY contain?
A. 0
B. 5
C. 7
D. 12
The following SAS program is submitted:
data work.totalsales;
set work.monthlysales(keep = year product sales);
retain monthsales {12};
array monthsales {12};
do i = 1 to 12;
monthsales{i} = sales;
end;
cnt + 1;
monthsales{cnt} = sales;
run;
The data set named WORK.MONTHLYSALES has one observation per month for each of five years for a total of 60 observations.
Which one of the following is the result of the above program?
A. The program fails execution due to data errors.
B. The program fails execution due to syntax errors.
C. The program runs with warnings and creates the WORK.TOTALSALES data set with 60 observations.
D. The program runs without errors or warnings and creates the WORK.TOTALSALES data set with 60 observations.
Unless specified, which variables and data values are used to calculate statistics in the MEANS procedure?
A. non-missing numeric variable values only
B. missing numeric variable values and non-missing numeric variable values only
C. nun-missing character variables and nun-missing numeric variable values only
D. missing character variables, nun-missing character variables, missing numeric variable values, and nun-missing numeric variable values
Which one of the following ODS statement options terminates output being written to an HTML file?
A. END
B. QUIT
C. STOP
D. CLOSE
A SAS program is submitted and the following SAS log is produced:
2 data gt100;
3 set ia.airplanes
4 if mpg gt 100 then output
22 202
ERROR: File WORK.IF.DATA does not exist.
ERROR: File WORK.MPG.DATA does not exist.
ERROR: File WORK.GT.DATA does not exist.
ERROR: File WORK.THEN.DATA does not exist.
ERROR: File WORK.OUTPUT DATA does not exist.
ERROR 22-322: Syntax error, expecting one of the following: a name, a quoted string, (,;, END, KEY, KEYS, NOBS, OPEN, POINT,_DATA_,_LAST_, NULL_
ERROR 202-322: The option or parameter is not recognized and will be ignored.
5 run;
The IA libref was previously assigned in this SAS session.
Which one of the following corrects the errors in the LOG?
A. Delete the word THEN on the IF statement.
B. Add a semicolon at the end of the SET statement.
C. Place quotes around the value on the IF statement.
D. Add an END statement to conclude the IF statement.
The contents of the raw data file NAMENUM are listed below: ----I----10---I----20---I----30 Joe xx
The following SAS program is submitted:
data test; infile `namenum'; input name $ number; run;
Which one of the following is the value of the NUMBER variable?
A. xx
B. Joe
C. (missing numeric value)
D. The value can not be determined as the program fails to execute due to errors.