SAS OnlineTutor HomeFAQ PageSuggested Learning PathsContents+Searchback||next

Quiz: Enhancing Reports

Select the best answer for each question and click Score My Quiz.

  1. TITLE statements stay in effect until . . .

     a.   you modify them.
     b.   you cancel them.
     c.   you end your SAS session.
     d.   all of the above.

  2. Which title(s) will appear on the second report produced by this program?
    proc print data=data.houses;
       title1 'Houses for Sale';
       title2 'Orange County';
    run;
    proc print data=data.houses;
       where style='Ranch';
       title3 'Ranch Houses';
    run; 

     a.   Ranch Houses

     b.   Houses for Sale
    Orange County
    Ranch Houses

     c.   Houses for Sale
    Orange County

     d.   Houses for Sale
    Ranch Houses

  3. Which statement cancels all of the titles currently in effect?
    title1 'Sales Report'
    title2  'Produce'
    proc print data=produce.sales;
        var store day sales1 sales2
    ?
    run;
    

     a.  
    title;
     b.  
    title1;
     c.  
    title2;
     d.  

    a or b

  4. Which footnote(s) will be displayed with the second report?
    
    footnote1 'Site 1 Data';
    footnote2 'Greater Metro Area';
    proc print data=air.quality;
       var date hour ozone windspeed;
    run;
    footnote1 'Site 2 Data';
    proc tabulate data=air.quality;
       var date hour ozone windspeed;
       table max*(ozone windspeed);
    run;

     a.   Greater Metro Area
    Site 2 Data

     b.   Site 1 Data
    Greater Metro Area

     c.   Site 2 Data

     d.   Greater Metro Area

  5. Which of the following is not true when assigning footnotes using the FOOTNOTES window?

     a.   The footnote text is enclosed in quotation marks.
     b.   The footnotes are not stored with your program.
     c.   The footnotes remain in effect only during your SAS session.
     d.   You issue the FOOTNOTES command to open the Footnotes window.

  6. Which of the following is not true for SAS formats?

     a.   They remain in effect only for the PROC statment in which they appear.
     b.   They control the way data values are displayed.
     c.   They control the way data values are stored.
     d.   They specify the total field width used for displaying the values in the output.

  7. Which SAS program creates the output shown below?

    Obs SquareFeet Bedrooms Baths Price
    1 1632 3 2.5 $151,900.00
    2 1692 4 2.5 $150,100.00
    3 1606 3 2 $150,000.00
    4 1708 3 2.5 $153,280.00
    5 1845 3 2 $153,500.00
    6 1499 3 2.5 $154,500.00

     a.  
    proc print data=data.houses;
       var squarefeet bedrooms baths price;
       format price dollar11.2;
    run; 
     
     b.  
    proc print data=data.houses;
       var squarefeet bedrooms baths price;
       format price dollar8.2;
    run; 
     
     c.  
    proc print data=data.houses;
       var squarefeet bedrooms baths price;
       format price comma 11.2;
    run; 
     
     d.  
    proc print data=data.houses;
      var squarefeet bedrooms baths price;
      format price comma8.2;
    run;  

  8. The FORMAT statement below displays the variable Total using . . .
    format total comma4.;  

     a.   commas and decimal places.
     b.   commas and no decimal places.
     c.   commas, dollar signs, and decimal places.
     d.   dollar signs and no decmal places.

  9. Which statement enables you to display the variable Store with the descriptive name Store Location?

     a.  
    'Store Location'=store;
     b.  
    store='store location';
     c.  
    label store='Store Location';
     d.  
    label store=Store Location;

  10. Which SAS program produced the output shown below?

    Obs Category Store Total Sales Total Returns
    1 Biography South Plaza 72.04 22.67
    2 Cooking South Plaza 117.09 25.21
    3 Fiction South Plaza 47.05 23.13
    4 Sci Fi South Plaza 50.09 21.91
    5 Self Help South Plaza 103.58 22.71

     a.  
    proc print data=sales.store label;
       var category store sales returns;
       label sales='Total Sales' returns='Total Returns';
       where store='South Plaza';
    run; 
     
     b.  
    proc print data=produce.sales label;
       var category store sales returns;
       label sales='Total Sales';
       label returns='Total Returns';
       where store='South Plaza';
    run; 
     
     c.  
    proc print data=sales.store;
       var category store sales returns;
       sales=Total Sales returns=Total Returns;
       where store='South Plaza';
    run; 
     
     d.   a or b



back||next

Terms of Use & Legal Information | Privacy Statement