Business Intelligence Quiz: Reading SAS Data Sets Overview

10 Questions | Total Attempts: 102

SettingsSettingsSettings
Please wait...
Business Intelligence Quizzes & Trivia

In the study of computing, the term “Statistical Analysis System” (or SAS) refers to a software suite developed by the SAS Institute for use in the fields of advanced analytics, multivariate analysis, business intelligence, predictive analytics, and data management. What do you know of SAS and how its data is recorded?


Questions and Answers
  • 1. 
    If you submit the following program, which variables appear in the new data set? data work.cardiac(drop=age group);    set clinic.fitness(keep=age weight group);    if group=2 and age>40; run;
    • A. 

      None

    • B. 

      Weight

    • C. 

      Age, Group

    • D. 

      Age, Weight, Group

  • 2. 
    Which of the following programs correctly reads the data set Orders and creates the data set FastOrdr?
    • A. 

      Data catalog.fastordr(drop=ordrtime);    set july.orders(keep=product units price);    if ordrtime<4;    Total=units*price; run;

    • B. 

      Data catalog.orders(drop=ordrtime);    set july.fastordr(keep=product units price);    if ordrtime<4;    Total=units*price; run;

    • C. 

      Data catalog.fastordr(drop=ordrtime);    set july.orders(keep=product units price                    ordrtime);    if ordrtime<4;    Total=units*price; run;

    • D. 

      None of the above

  • 3. 
    Which of the following Statements is false about BY-group processing?      When you use the BY statement with the SET statement:
    • A. 

      The data sets listed in the SET statement must be indexed or sorted by the values of the BY variable(s).

    • B. 

      The DATA step automatically creates two variables, FIRST., and LAST., for each variable in the BY statement.

    • C. 

      FIRST. and LAST. identify the first and last observation in each BY group, respectively.

    • D. 

      FIRST. and LAST. are stored in the data set.

  • 4. 
    There are 500 observations in the data set Usa.  What is the result of submitting the following program? data work.getobs5(drop=obsnum);    obsnum=5;    set company.usa(keep=manager payroll) point=obsnum;    stop; run;
    • A. 

      An error

    • B. 

      An empty data set

    • C. 

      Continuous loop

    • D. 

      A data set that contains one observation

  • 5. 
    There is no end-of-file condition when you use direct access to read data, so how can your program prevent a continuous loop?
    • A. 

      Do not use a POINT= variable.

    • B. 

      Check for an invalid value of the POINT= variable.

    • C. 

      Do not use an END= variable.

    • D. 

      Include an OUTPUT statement.

  • 6. 
    Assuming that the data set Company.USA has five or more observations, what is the result of submitting the following program? data work.getobs5(drop=obsnum);    obsnum=5; set company.usa(keep=manager payroll) point=obsnum;    output;    stop; run;  
    • A. 

      An error

    • B. 

      An empty data set

    • C. 

      A continuous loop

    • D. 

      A data set that contains one observation

  • 7. 
    Which of the statements is true regarding direct access of data sets?
    • A. 

      You cannot specify END= with POINT=.

    • B. 

      You cannot specify OUTPUT with POINT=.

    • C. 

      You cannot specify STOP with END=.

    • D. 

      You cannot specify FIRST. with LAST.

  • 8. 
    What is the result of submitting the following program? data work.addtoend;    set clinic.stress2 end=last;    if last; run;
    • A. 

      An error

    • B. 

      An empty data set

    • C. 

      A continuous loop

    • D. 

      A data set that contains one observation

  • 9. 
    At the start of DATA step processing, during the compilation phase, variables are created in the program data vector (PDV), and observations are set to:
    • A. 

      Blank

    • B. 

      Missing

    • C. 

      0

    • D. 

      There are not observations

  • 10. 
    The DATA step executes:
    • A. 

      Continuously if you use the POINT= option and the STOP statement.

    • B. 

      Once for each variable in the output data set.

    • C. 

      Once for each observation in the input data set.

    • D. 

      Until it encounters and OUTPUT statement.

Back to Top Back to top