SAS Chapter 10 Producing HTML Output

Approved & Edited by ProProfs Editorial Team
The editorial team at ProProfs Quizzes consists of a select group of subject experts, trivia writers, and quiz masters who have authored over 10,000 quizzes taken by more than 100 million users. This team includes our in-house seasoned quiz moderators and subject matter experts. Our editorial experts, spread across the world, are rigorously trained using our comprehensive guidelines to ensure that you receive the highest quality quizzes.
Learn about Our Editorial Process
| By Moxleyv
M
Moxleyv
Community Contributor
Quizzes Created: 38 | Total Attempts: 21,511
Questions: 10 | Attempts: 726

SettingsSettingsSettings
SAS Chapter 10 Producing HTML Output - Quiz

Practice for the SAS basic certification exam


Questions and Answers
  • 1. 

    Using the ODS statements, how many types of output can you generate at once?

    • A.

      1(only listing output)

    • B.

      2

    • C.

      3

    • D.

      As many as you want

    Correct Answer
    D. As many as you want
    Explanation
    You can generate any number of output types as long as you open the ODS destination for each type of output you want to create.

    Rate this question:

  • 2. 

    If ODS is set to its default settings, what types of output are created by the code below? ods html file='c:\myhtml.htm'; ods pdf file='c:\mypdf.pdf';

    • A.

      HTML and PDF

    • B.

      PDF only

    • C.

      HTML, PDF, and listing

    • D.

      No output is created because ODS is closed by default.

    Correct Answer
    C. HTML, PDF, and listing
    Explanation
    Listing output is created by default, so these statements create HTML, PDF, and listing output.

    Rate this question:

  • 3. 

    What is the purpose of closing the Listing destination in the code shown below? ods listing close; ods html ... ;

    • A.

      It conserves system resources

    • B.

      It simplifies your program.

    • C.

      It makes your program compatible with other hardware platforms.

    • D.

      It makes your program compatible with previous versions of SAS.

    Correct Answer
    A. It conserves system resources
    Explanation
    By default, SAS programs produce listing output. If you want only HTML output, it's a good idea to close the LIsting destination before creating HTML output, as an open destination uses system resources.

    Rate this question:

  • 4. 

    When the code shown below is run, what will your file D:\Output\body.html contain? ods html body='d:\output\body.html'; proc print data=work.alpha; run; proc print data=work.beta; run; ods html close;

    • A.

      The PROC PRINT output for Work.Alpha.

    • B.

      The PROC PRINT output for Work.Beta.

    • C.

      The PROC PRINT output for both Work.Alpha and Work.Beta.

    • D.

      Nothing. No output will be written to D:\Output\body.html

    Correct Answer
    C. The PROC PRINT output for both Work.AlpHa and Work.Beta.
    Explanation
    When multiple procedures are run while HTML output is open, procedure output is appended to the same body file.

    Rate this question:

  • 5. 

    When the code shown below is run, what file will be loaded by the links in D:\Output\contents.html? ods html body='d:\output\body.html'          contents='d:\output\contents.html'          frame='d:\output\frame.html';

    • A.

      D:\Output\body.html

    • B.

      D:\Output\contents.html

    • C.

      D:\Output\frame.html

    • D.

      There are no links from the file D:\Output\contents.html.

    Correct Answer
    A. D:\Output\body.html
    Explanation
    The CONTENTS=option creates a table of contents containing links to the body file, D:\Output\body.html.

    Rate this question:

  • 6. 

    The table of contents created by the CONTENTS= option contains a numbered heading for

    • A.

      Each procedure.

    • B.

      Each procedure that creates output.

    • C.

      Each procedure and DATA step.

    • D.

      Each HTML file created by your program.

    Correct Answer
    B. Each procedure that creates output.
    Explanation
    The table of contents contains a numbered heading for each procedure that creates output.

    Rate this question:

  • 7. 

    When the code shown below is run, what will the file D:\Output\frame.html display? ods html body='d:\output\body.html'          contents='d:\output\contents.html'          frame='d:\output\frame.html';

    • A.

      The file D:\Output\contents.html.

    • B.

      The file D:\Output\frame.html.

    • C.

      The files D:\Output\frame.html and D:\Output\contents.html.

    • D.

      It displays no other files.

    Correct Answer
    C. The files D:\Output\frame.html and D:\Output\contents.html.
    Explanation
    The FRAME= option creates HTML file that integrates the table of contents and the body file.

    Rate this question:

  • 8. 

    What is the purpose of the URL= suboptions shown below? ods html body='d:\output\body.html' (url='body.html')          contents='d:\output\contents.html'          (url='contents.html')          frame='d:\output\frame.html';

    • A.

      To create absolute link addresses fro loading the files from a server.

    • B.

      To create relative link addresses for loading the files from a server.

    • C.

      To allow HTML files to be loaded from a local drive.

    • D.

      To send HTML output to two locations.

    Correct Answer
    B. To create relative link addresses for loading the files from a server.
    Explanation
    Specifying the URL= suboption in the file specification provides a URL that ODS uses in the links it creates. Specifying a simple (one name) URL creates a relative link address to the file.

    Rate this question:

  • 9. 

    Which ODS HTML option was used in creating the following table?

    • A.

      Format=brown

    • B.

      Format='brown'

    • C.

      Style=brown

    • D.

      Style='brown'

    Correct Answer
    C. Style=brown
    Explanation
    You can change the appearance of HTML output by using the STYLE= option in the ODS HTML statement. The style name doesn't need quotation marks.

    Rate this question:

  • 10. 

    What is the purpose of the PATH= option? ods html path='d:output' (url=none)          body='body.html'          contents='contents.html'          frame='frame.html';

    • A.

      It creates absolute link addresses for loading HTML files from a server.

    • B.

      It creates relative link addresses for loading HTML files from a server.

    • C.

      It allows HTML files to be loaded from a local drive.

    • D.

      It specifies the location of HTML file output.

    Correct Answer
    D. It specifies the location of HTML file output.
    Explanation
    You use the PATH=option to specify the location for HTML files to be stored. When you use the PATH= option, you don't need to specify the full path name for the body, contents, or frame files.

    Rate this question:

Quiz Review Timeline +

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

  • Current Version
  • Aug 21, 2023
    Quiz Edited by
    ProProfs Editorial Team
  • Jan 24, 2013
    Quiz Created by
    Moxleyv

Related Topics

Advertisement
×

Wait!
Here's an interesting quiz for you.

We have other quizzes matching your interest.