Statistics > EXAM > STAT 330 Midterm Exam | Questions with 100% Correct Answers (All)

STAT 330 Midterm Exam | Questions with 100% Correct Answers

Document Content and Description Below

STAT 330 Midterm Exam | Questions with 100% Correct Answers Which of the following is not a comment in SAS? a. / I am not a comment / b. * I am not a comment ; c. / I am not a comment ; */ d. All of... the above are valid comments In SAS data sets, missing numeric data are represented by which of the following? a. A single space b. A single period c. Any number of spaces d. Any of the above Which of the following assignment statements is valid for the numeric variable Score? a. Score / 100; b. Score = Score / 100; c. Score = 'Score' / 100; d. Score = 'Score / 100'; Which of the following IF-THEN statements will not assign a value of 1 to the variable named Flag for patients with an eye color of blue or brown? a. IF EyeColor = 'blue' OR 'brown' THEN Flag = 1; b. IF EyeColor = 'blue' OR EyeColor = 'brown' THEN Flag = 1; Incorrect c. IF EyeColor IN ('blue', 'brown') THEN Flag = 1; d. All of the above will work Which set of IF-THEN/ELSE statements will run without errors? a. IF 0 <= Age <= 50 THEN Group = 'A'; ELSE 50 < Age <= 70 THEN Group = 'B'; ELSE Age > 70 THEN Group = 'C'; b. IF 0 <= Age <= 50 THEN Group = 'A'; ELSE IF 50 < Age <= 70 THEN Group = 'B'; ELSE Age > 70 THEN Group = 'C'; c. IF 0 <= Age <= 50 THEN Group = 'A'; ELSE IF 50 < Age <= 70 THEN Group = 'B'; ELSE IF Age > 70 THEN Group = 'C'; d. All of the above will work What other term is appropriate for referring to a SAS data set? a. A column b. A row c. A table d. None of the above Which of the following is a valid variable name? a. AbCdEfGhIjKlMnOpQrStUvWxYz b. %Change c. Debt-Ratio d. 1stProcedure How many SAS statements does this program contain? DATA instock; INFILE supply; INPUT Brand $ Model $ Quantity; RUN; PROC PRINT DATA = instock; RUN; a. 2 b. 3 c. 6 d. 7 Which statement does not indicate the end of a DATA or PROC step? . STOP b. QUIT c. END d. RUN By default, SAS will execute the DATA step one time each for which of the following? a. Variable b. Observation c. Data set d. Procedure What is the main difference in the naming convention for SAS librefs versus SAS variables? a. Librefs can contain special characters such as $, %, and # b. Variable names are case sensitive c. Librefs can only be up to 8 characters long d. Variable names can contain underscores What is a SAS library? a. A folder that can contain SAS data sets b. The location where the SAS log messages are stored c. The location of the SAS online help d. All of the above The data in the following program are an example of what type of data? DATA readme; INPUT PLACE $ CODE $; DATALINES; AG 5678 SLO 1234 PB 3456 ; RUN; a. Character b. Instream c. Internal raw data d. All of the above Which statement is synonymous with a DATALINES statement? a. DATA b. INFILE c. CARDS d. INPUT Which SAS statement allows you to refer to an external raw data file? a. DATALINES b. DATA c. INFILE d. INPUT Which of the following is a valid libref name that can be used to create a permanent SAS data set? a. working b. 365days c. permanent d. All of the above Which PROC PRINT will print a permanent SAS data set called DOGS assuming that all SAS libraries have been properly defined? a. PROC PRINT DATA = dogs.sas7bdat; RUN; b. PROC PRINT DATA = dogs; RUN; c. PROC PRINT DATA = sasdata.dogs; RUN; d. None of the above When using the following direct reference to create a permanent SAS data set in the Windows operating environment, what does the name dogs refer to? DATA 'c:\MySASLib\dogs'; a. The drive b. The directory c. The filename d. The libref Array function ARRAY name (n) $ variable-list; IF-THEN/ELSE function IF condition THEN action; IF condition THEN DO action; action; IF condition AND condition THEN action; ...ELSE IF condition THEN action; ...ELSE action; (AND = all conditions must be true) (OR = only one condition must be true) DATALINES function INPUT $variable-list; DO i-(n); .............................. END; DATALINES ..... ...... ..... ..... ..... ..... .... ..... ..... ; The following code will create the variables: car1, car2, car3. array car (3); a. True b. False Which symbol is needed to create a character array instead of a numeric array? a. @ b. $ c. & d. None of the above What is the value of x in the resulting data set? data temp; x = 1; do i = 1 to 5; x = x + 1; end; run; x = 6 How many times will the following loop execute? data loop; x = 5; do while (x < 4); x = x +1; end; run; 0 How many times will the following loop execute? data loop; x = 3; do until (x <= 6); x = x + 1; end; run; 1 Which of the following is a valid function for finding the average of X1, X2, and X3? a. AVERAGE(X1,X2,X3) b. AVG(X1,X2,X3) [Show More]

Last updated: 8 months ago

Preview 4 out of 13 pages

Buy Now

Instant download

We Accept:

We Accept
loader

Loading document previews ...

Buy this document to get the full access instantly

Instant Download Access after purchase

Buy Now

Instant download

We Accept:

We Accept

Reviews( 0 )

$12.00

Buy Now

We Accept:

We Accept

Instant download

Can't find what you want? Try our AI powered Search

17
0

Document information


Connected school, study & course


About the document


Uploaded On

Oct 01, 2024

Number of pages

13

Written in

Seller


seller-icon
Nurse Henny

Member since 2 years

8 Documents Sold

Additional information

This document has been written for:

Uploaded

Oct 01, 2024

Downloads

 0

Views

 17

Document Keyword Tags

Recommended For You

Get more on EXAM »

$12.00
What is Scholarfriends

In Scholarfriends, a student can earn by offering help to other student. Students can help other students with materials by upploading their notes and earn money.

We are here to help

We're available through e-mail, Twitter, Facebook, and live chat.
 FAQ
 Questions? Leave a message!

Follow us on
 Twitter

Copyright © Scholarfriends · High quality services·