SAS Chapter 1 Basic Concepts

Reviewed by Editorial Team
The ProProfs editorial team is comprised of experienced subject matter experts. They've collectively created over 10,000 quizzes and lessons, serving over 100 million users. Our team includes in-house content moderators and subject matter experts, as well as a global network of rigorously trained contributors. All adhere to our comprehensive editorial guidelines, ensuring the delivery of high-quality content.
Learn about Our Editorial Process
| By Moxleyv
M
Moxleyv
Community Contributor
Quizzes Created: 38 | Total Attempts: 21,992
| Attempts: 1,782 | Questions: 10
Please wait...
Question 1 / 10
0 %
0/100
Score 0/100
1. What type of variable is the variable Wear in the data set below, assuming that there is a missing value in the data set?

Explanation

It must be a numeric variable, because the missing value is indicated by a period rather than a blank.

Submit
Please wait...
About This Quiz
SAS Chapter 1 Basic Concepts - Quiz

This quiz assesses fundamental SAS concepts, focusing on data handling, program processing, and variable types. It tests understanding of observation and variable counts, program step execution, and variable... see moreclassification, essential for learners pursuing SAS proficiency. see less

2. What type of variable is the variable AcctNum in the data set below?

Explanation

It must be a character variable, because the values contain letters and underscores, which are not valid characters for numeric values.

Submit
3. Which of the following files is a permanent SAS file?

Explanation

To store a file permanently in a SAS data library, you assign it a libref other than the default Work. For example, by assigning the libref Profits to a SAS data library, you specify that files within the library are to be stored until you delete them. Therefore, SAS files in the Sashelp and Sasuser libraries are permanent files.

Submit
4. What is a SAS library?

Explanation

Every SAS file is stored in a SAS library, which is a collection of SAS files, such as SAS data sets and catalogs. In some operating environments, a SAS library is a physical collection of files. In others, the files are only logically related. In the Windows and UNIX environments, a SAS library is typically a group of SAS files in the same folder or directory.

Submit
5. Which of the following variable names is valid?

Explanation

Variable names follow the same rules as SAS data set names. They can be 1 to 32 characters long, must begin with a letter(A-Z, either uppercase or lowercase) or an underscore, and can continue with any combination of numbers, letters, or underscores.

Submit
6. What is the default length for the numeric variable Balance?

Explanation

The numeric variable Balance has a default length of 8. Numeric values (no matter how many digits they contain) are stored in 8 bytes of storage unless you specify a different length.

Submit
7. How many observations and variables does the data set below contain?

Explanation

The data set displayed in the image contains:

4 observations: Adams, Geller, Martinez, Noble

2 variables: Name and Balance

Thus, the correct choice based on standard interpretations is missing from the provided options. Each row represents an observation (an individual account with a balance), and each column represents a variable (one for names, and one for balances). There are 4 observations (the individuals named Adams, Geller, Martinez, and Noble) and 2 variables (Name and Balance). If you need the response to match one of your provided choices, please verify the options or provide additional context.

Submit
8. In a DATA step, how can you reference a temporary SAS data set named Forecast?

Explanation

To reference a temporary SAS file in a DATA step or PROC step, you can specify the one-level name of the file (for example, Forecast) or the two-level name using the libref Work (for example, Work.Forecast).

Submit
9. How many steps are executed when the program below is processed? data user.tables;      infile jobs;      input date name $ job $; run; proc sort data=user.tables;      by name; run; proc print data=user.tables; run;

Explanation

When it encounters a DATA, PROC, or RUN statement, SAS stops reading statements and executes the previous step in the program. The program above contains one DATA step and two PROC steps, for a total of three program steps.

Submit
10. How many statements does the following SAS program contain? proc print data=new.prodsale           label double;      var state day price1 price2; where state='NC';      label state='Name of State'; run;

Explanation

The five statements are: 1) the PROC PRINT statement (two lines long); 2) the VAR statement; 3) the WHERE statement (on the same line as the VAR statement); 4) the LABEL statement; and 5) the RUN statement (on the same line as the LABEL statement).

Submit
View My Results

Quiz Review Timeline (Updated): Jun 17, 2024 +

Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.

  • Current Version
  • Jun 17, 2024
    Quiz Edited by
    ProProfs Editorial Team
  • Jan 09, 2013
    Quiz Created by
    Moxleyv
Cancel
  • All
    All (10)
  • Unanswered
    Unanswered ()
  • Answered
    Answered ()
What type of variable is the variable Wear in the data set below,...
What type of variable is the variable AcctNum in the data set below?
Which of the following files is a permanent SAS file?
What is a SAS library?
Which of the following variable names is valid?
What is the default length for the numeric variable Balance?
How many observations and variables does the data set below contain?
In a DATA step, how can you reference a temporary SAS data set named...
How many steps are executed when the program below is processed?...
How many statements does the following SAS program contain?...
Alert!

Advertisement