PLOT Statement

PLOT <plot-options> </ graph-options> ;

The PLOT statement produces a graph or set of graphs for the sample size analysis defined by the previous POWER statement. The plot-options define the plot characteristics, and the graph-options are like those in SAS/GRAPH software. If ODS Graphics is enabled, then the PLOT statement uses ODS Graphics to create graphs. For example:

ods listing style=htmlbluecml;
ods graphics on;

proc glmpower data=Exemplary;
   class Variety Exposure;
   model Height = Variety | Exposure;
   power
      stddev = 4 6.5
      ntotal = 60
      power  = .;
   plot x=n min=30 max=90;
run;

ods graphics off;

Otherwise, traditional graphics are produced. For example:

ods graphics off;

proc glmpower data=Exemplary;
   class Variety Exposure;
   model Height = Variety | Exposure;
   power
      stddev = 4 6.5
      ntotal = 60
      power  = .;
   plot x=n min=30 max=90;
run;

For more information about enabling and disabling ODS Graphics, see the section Enabling and Disabling ODS Graphics in Chapter 21, Statistical Graphics Using ODS.

The ODS LISTING STYLE=HTMLBLUECML statement specifies the HTMLBLUECML style, which is suitable for use with PROC GLMPOWER because it allows both marker symbols and line styles to vary. See the section ODS Styles Suitable for Use with PROC GLMPOWER for more information.

Options

You can specify the following plot-options in the PLOT statement.

INTERPOL=JOIN | NONE

specifies the type of curve to draw through the computed points. The INTERPOL=JOIN option connects computed points with straight lines. The INTERPOL=NONE option leaves computed points unconnected.

KEY=BYCURVE <( bycurve-options )>
KEY=BYFEATURE <( byfeature-options )>
KEY=ONCURVES

specifies the style of key (or "legend") for the plot. The default is KEY=BYFEATURE, which specifies a key with a column of entries for each plot feature (line style, color, and/or symbol). Each entry shows the mapping between a value of the feature and the value(s) of the analysis parameter(s) linked to that feature. The KEY=BYCURVE option specifies a key with each row identifying a distinct curve in the plot. The KEY=ONCURVES option places a curve-specific label adjacent to each curve.

You can specify the following byfeature-options in parentheses after the KEY=BYCURVE option.
NUMBERS=OFF | ON

specifies how the key should identify curves. If NUMBERS=OFF, then the key includes symbol, color, and line style samples to identify the curves. If NUMBERS=ON, then the key includes numbers matching numeric labels placed adjacent to the curves. The default is NUMBERS=ON.

POS=BOTTOM | INSET

specifies the position of the key. The POS=BOTTOM option places the key below the X axis. The POS=INSET option places the key inside the plotting region and attempts to choose the least crowded corner. The default is POS=BOTTOM.

You can specify the following byfeature-options in parentheses after KEY=BYFEATURE option.
POS=BOTTOM | INSET

specifies the position of the key. The POS=BOTTOM option places the key below the X axis. The POS=INSET option places the key inside the plotting region and attempts to choose the least crowded corner. The default is POS=BOTTOM.

MARKERS=ANALYSIS | COMPUTED | NICE | NONE

specifies the locations for plotting symbols.

The MARKERS=ANALYSIS option places plotting symbols at locations corresponding to the values of the relevant input parameter from the POWER statement preceding the PLOT statement.

The MARKERS=COMPUTED option (the default) places plotting symbols at the locations of actual computed points from the sample size analysis.

The MARKERS=NICE option places plotting symbols at tick mark locations (corresponding to the argument axis).

The MARKERS=NONE option disables plotting symbols.

MAX=number | DATAMAX

specifies the maximum of the range of values for the parameter associated with the "argument" axis (the axis that is not representing the parameter being solved for). The default is DATAMAX, which specifies the maximum value that occurs for this parameter in the POWER statement that precedes the PLOT statement.

MIN=number | DATAMIN

specifies the minimum of the range of values for the parameter associated with the "argument" axis (the axis that is not representing the parameter being solved for). The default is DATAMIN, which specifies the minimum value that occurs for this parameter in the POWER statement that precedes the PLOT statement.

NPOINTS=number
NPTS=number

specifies the number of values for the parameter associated with the "argument" axis (the axis that is not representing the parameter being solved for). You cannot use the NPOINTS= and STEP= options simultaneously. The default value for typical situations is 20.

STEP=number

specifies the increment between values of the parameter associated with the "argument" axis (the axis that is not representing the parameter being solved for). You cannot use the STEP= and NPOINTS= options simultaneously. By default, the NPOINTS= option is used instead of the STEP= option.

VARY ( feature <BY parameter-list> <, ..., feature <BY parameter-list>> )

specifies how plot features should be linked to varying analysis parameters. Available features are COLOR, LINESTYLE, PANEL, and SYMBOL. A "panel" refers to a separate plot with a heading identifying the subset of values represented in the plot.

The parameter-list is a list of one or more names separated by spaces. Each name must match the name of an analysis option used in the POWER statement preceding the PLOT statement, or one of the following keywords: SOURCE (for the tests) and DEPENDENT (for the cell means scenarios). Also, the name must be the primary name for the analysis option—that is, the one listed first in the syntax description.

If you omit the < BY parameter-list > portion for a feature, then one or more multivalued parameters from the analysis will be automatically selected for you.

X=N | POWER

specifies a plot with the requested type of parameter on the X axis and the parameter being solved for on the Y axis. When X=N, sample size is assigned to the X axis. When X=POWER, power is assigned to the X axis. You cannot use the X= and Y= options simultaneously. The default is X=POWER, unless the result parameter is power, in which case the default is X=N.

XOPTS= ( x-options )

specifies plot characteristics pertaining to the X axis.

You can specify the following x-options in parentheses.
CROSSREF=NO | YES

specifies whether the reference lines defined by the REF= x-option should be crossed with a reference line on the Y axis that indicates the solution point on the curve.

REF=number-list

specifies locations for reference lines extending from the X axis across the entire plotting region. See the section Specifying Value Lists in the POWER Statement for information about specifying the number-list.

Y=N | POWER

specifies a plot with the requested type of parameter on the Y axis and the parameter being solved for on the X axis. When Y=N, sample size is assigned to the Y axis. When Y=POWER, power is assigned to the Y axis. You cannot use the Y= and X= options simultaneously. By default, the X= option is used instead of the Y= option.

YOPTS= ( y-options )

specifies plot characteristics pertaining to the Y axis.

You can specify the following y-options in parentheses.

CROSSREF=NO | YES

specifies whether the reference lines defined by the REF= y-option should be crossed with a reference line on the X axis that indicates the solution point on the curve.

REF=number-list

specifies locations for reference lines extending from the Y axis across the entire plotting region. See the section Specifying Value Lists in the POWER Statement for information about specifying the number-list.

You can specify the following graph-options in the PLOT statement after a slash (/).

DESCRIPTION=’string

specifies a descriptive string of up to 40 characters that appears in the "Description" field of the graphics catalog. The description does not appear on the plots. By default, PROC GLMPOWER assigns a description either of the form "Y versus X" (for a single-panel plot) or of the form "Y versus X (S)," where Y is the parameter on the Y axis, X is the parameter on the X axis, and S is a description of the subset represented on the current panel of a multipanel plot.

NAME=’string

specifies a name of up to eight characters for the catalog entry for the plot. The default name is PLOTn, where n is the number of the plot statement within the current invocation of PROC GLMPOWER. If the name duplicates the name of an existing entry, SAS/GRAPH software adds a number to the duplicate name to create a unique entry—for example, PLOT11 and PLOT12 for the second and third panels of a multipanel plot generated in the first PLOT statement in an invocation of PROC GLMPOWER.