Using ODS LAYOUT in order to print two plots on the same page

From PHUSE Wiki
Jump to: navigation, search


There are several examples or analysis where more than one figure needs to be placed on one page. For example it is always useful to place the linear and the semilogarithmic plasma concentration profiles on the same page.

This little example will show how this can easily be done with some ODS LAYOUT without distortion.


ODS LAYOUT is used to devide the page into several sections for the different plot statements.

  • It is necessary to start the layout definitions with the statement ODS LAYOUT START.
  • Then the plot areas of the page can be defined by using ODS REGION.
  • The upper left corner of the REGION is defined by X=Percentage and Y=Percentage.
  • HEIGHT and WIDTH define the total height and total width of the region.
  • ODS REGION statements are used before each piece of output to place the output in a section of the page.
  • Finally, the statement ODS LAYOUT END closes the layout definitions.

Example for Program Specifications

In this example ODS LAYOUT is used to divide one page into two sections.

Note that the ODS Region defines the different regions on the page.

options center;

footnote9 j=l "Program: &pgmname" j=r "Page 1 of 1";

*** Produce figure for linear scale with PROC PLOT (for all available subjects) ***;
ods layout start;

goptions ctitle=white htitle=0pct ;
options nocenter; 


ods region x=0pct y= 0pct height=100pct width=53pct;


*** Produce figure for semilog scale with PROC PLOT (for all available subjects) ***;

ods region x=50pct y= 0pct height=100pct width=52pct;

ods layout end;