Chapter Contents
Chapter Contents
Previous
Previous
Next
Next
Using the Output Delivery System

Example 15.5: Excluding ODS Tables from Display

The following example demonstrates how you can use the ODS EXCLUDE statement to exclude particular tables from ODS destinations. This example also creates a SAS data set from the excluded table.

The data are from Hemmerle and Hartley (1973). The response variable consists of measurements from an oven experiment, and the model contains a fixed effect A and random effects B and A*B.

   data hh;
      input a b y @@;
      datalines;
   1 1 237   1 1 254    1 1 246
   1 2 178   1 2 179
   2 1 208   2 1 178    2 1 187
   2 2 146   2 2 145    2 2 141
   3 1 186   3 1 183
   3 2 142   3 2 125    3 2 136
   ;
   ods html body='mixed.htm'
            contents='mixedc.htm'
            frame='mixedf.htm';

   ods exclude ParmSearch(persist);
   ods show;

The ODS HTML statement specifies the filenames to contain the output generated from the statements that follow.

The ODS EXCLUDE statement excludes the table "ParmSearch" from display. Although the table is excluded from the displayed output, the information contained in the "ParmSearch" table is graphically summarized in a later step.

The PERSIST option in the ODS EXCLUDE statement excludes the table for the entire SAS session or until you execute an ODS SELECT statement or an ODS EXCLUDE NONE statement. If you omit the PERSIST option, the exclusion list is cleared when the procedure terminates.

The resulting exclusion list is displayed in Output 15.5.1.

Output 15.5.1: Results of the ODS SHOW Statement, Before PROC MIXED

           ods exclude ParmSearch(persist);
           ods show;

Current OVERALL exclude list is: 
1. ParmSearch(PERSIST)


The following ODS OUTPUT statement outputs the table "ParmSearch" to a SAS data set called parms. The MIXED procedure is invoked and the model is fit. All output from the MIXED procedure, except the "ParmSearch" table, is delivered to the HTML destination and the SAS listing. The ODS SHOW statement again displays the overall current exclusion list.

   ods output ParmSearch=parms;
   proc mixed data=hh asycov mmeq mmeqsol covtest;
      class a b;
      model y = a / outp=predicted;
      random b a*b;
      lsmeans a;
      parms (17 to 20 by 0.1) (.3 to .4 by .005) (1.0);
   run;

   ods show;

The results of the ODS SHOW statement, given after the MIXED procedure has terminated, are displayed in Output 15.5.2.

Output 15.5.2: Results of the ODS SHOW Statement, After PROC MIXED

           proc mixed data=hh asycov mmeq mmeqsol covtest;
              class a b;
              model y = a / outp=predicted;
              random b a*b;
              lsmeans a;
              parms (17 to 20 by .1) (.3 to .4 by .005) (1.0);
           run;
           ods show;

Current OVERALL exclude list is: 
1. ParmSearch(PERSIST)

Normally the ODS exclusion list is cleared at the conclusion of a procedure (for more information on ODS exclusion and selection lists, see the section "Using the Output Delivery System"). However, the PERSIST option in the preceding ODS EXCLUDE statement specifies that the "ParmSearch" table should remain in the exclusion list until the list is explicitly cleared (that is, when the ODS EXCLUDE NONE statement or an ODS SELECT statement is encountered). Output 15.5.2 shows that the exclusion list remains in effect after PROC MIXED terminates.

The PERSIST option is useful when you want to exclude the same table in further analyses during your SAS session.

The "ParmSearch" table is contained in the parms data set (as specified in the ODS OUTPUT statement). The information is plotted with the G3D procedure in the following step:

   proc g3d data=parms;
      plot CovP1*CovP2 = ResLogLike /
                 ctop=red cbottom=blue caxis=black;
   run;

   ods html close;

The MIXED procedure output resulting from the preceding statements is displayed in Output 15.5.3. The table of contents shows the names for all of the output tables. The "ParmSearch" table is not listed in the table of contents because of the preceding ODS EXCLUDE statement.

Output 15.5.3: HTML Output from the Mixed Procedure
odse5c.gif (17440 bytes)

The results of the G3D procedure is displayed in Output 15.5.4. The large amount of information contained in the table, which is excluded from display, can be summarized with a single plot.

Output 15.5.4: Plot of the ParmSearch Data Set
odse5h.gif (23209 bytes)

Chapter Contents
Chapter Contents
Previous
Previous
Next
Next
Top
Top

Copyright © 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.