• Print  |
  • Feedback  |

TEMPLATE Procedure: Plot Statements (Preproduction)

BARCHARTPARM Statement


Displays bars representing frequencies or weights specified by parameters, and typically is used to create a bar chart.
BARCHARTPARM X= column | expression Y= numeric-column | expression < / option(s)> ;


Required Arguments

X

specifies the column for the category values. Each X value is always treated as a unique value. The bars in the chart appear in the order that the X values are present in the data.

Y

specifies the column for the response values.


Options

BARCHARTPARM Options
Option Description
BACKGROUND= color | style-reference Specifies the background color of the graph.
BACKTRANSPARENCY= number Specifies the degree of the transparency of the background color.
DATATRANSPARENCY= number Specifies the degree of the transparency of the bars.
FILL= boolean Specifies whether to fill the interior of the bars.
FILLCOLOR= color | style-reference Specifies the color of the interior fill of the bars.
GRIDTRANSPARENCY= number Specifies the degree of the transparency of the grid lines.
GROUP= column Creates a separate segment within each bar for each unique group value of the specified column.
ORIENT= HORIZONTAL | VERTICAL Specifies the orientation of the Y axis and the bars.
OUTLINECOLOR= color | style-reference Specifies the color of the outlines around the bars.
TIP= ( column-list ) Specifies the information to display when the cursor is positioned over a graph element in the data area.
TRANSPARENCY= number Specifies the degree of the transparency of the bars, background, grid, wall, and axis elements, if displayed in a graph.
WALLTRANSPARENCY= number Specifies the degree of the transparency of the graph wall.
XAXIS= X | X2 Specifies whether data is mapped to the primary X axis or the secondary X (X2) axis.
XAXISOPTS= ( axis-options ) Specifies one or more X axis options.
XGRID= boolean Specifies whether grid lines are drawn at the tick marks.
YAXIS= Y | Y2 Specifies whether data is mapped to the primary Y axis or the secondary Y (Y2) axis.
YAXISOPTS= ( axis-options ) Specifies one or more Y axis options.
YERRORLOWER= numeric-column Specifies the values of the lower endpoints on the Y error bars.
YERRORUPPER= numeric-column Specifies the values of the upper endpoints on the Y error bars.
YGRID= boolean Specifies whether grid lines drawn at the tick marks.

BACKGROUND= color | style-reference

specifies the background color of the graph.

Default: Specified by the GraphBackground:Background style reference.
Interaction: Ignored in a LAYOUT OVERLAY block. For information, see Ignored Plot Options in a LAYOUT OVERLAY Block.
BACKTRANSPARENCY= number

specifies the degree of the transparency of the background color.

Default: 0
Range: 0 (opaque) to 1 (entirely transparent)
Interaction: The BACKTRANSPARENCY= option overrides the TRANSPARENCY= option for the background.
Interaction: Ignored in a LAYOUT OVERLAY block. For information, see Ignored Plot Options in a LAYOUT OVERLAY Block.
See also: TRANSPARENCY= option
DATATRANSPARENCY= number

specifies the degree of the transparency of the bars.

Default: 0
Range: 0 (opaque) to 1 (entirely transparent)
Interaction: The DATATRANSPARENCY= option overrides the TRANSPARENCY= option for the bars.
See also: TRANSPARENCY= option
FILL= boolean

specifies whether to fill the interior of the bars.

Default: TRUE
FILLCOLOR= color | style-reference

specifies the color of the interior fill of the bars.

Default: Specified by the GraphDataDefault:Foreground style reference.
GRIDTRANSPARENCY= number

specifies the degree of the transparency of the grid lines.

Default: 0
Range: 0 (opaque) to 1 (entirely transparent)
Interaction: The GRIDTRANSPARENCY= option overrides the TRANSPARENCY= option for the grid lines.
Interaction: Ignored in a LAYOUT OVERLAY block. For information, see Ignored Plot Options in a LAYOUT OVERLAY Block.
See also: TRANSPARENCY= option
GROUP= column

creates a separate segment within each bar for each unique group value of the specified column.

ORIENT= HORIZONTAL | VERTICAL

specifies the orientation of the Y axis and the bars.

Default: VERTICAL
OUTLINECOLOR= color | style-reference

specifies the color of the outlines around the bars.

Default: Specified by the GraphOutlines:Foreground style reference.
TIP= ( column-list )

specifies the information to display when the cursor is positioned over a graph element.

Default: All of the variables specified for the graph.
Requirement: You can activate tool tips in a SAS program by specifying an ODS GRAPHICS statement that has IMAGEFMT=STATICMAP specified.
Requirement: Tool tips are only available for graphs that are written to the ODS HTML destination. Tool tips are only displayed if they are activated by the SAS program that generates the ODS graphics output.
TRANSPARENCY= number

specifies the degree of the transparency of the bars, background, grid, wall, and axis elements, if displayed in a graph.

Default: 0
Range: 0 (opaque) to 1 (entirely transparent)
Interaction: You can specify the transparency of individual graph elements by using the BACKTRANSPARENCY=, DATATRANSPARENCY=, GRIDTRANSPARENCY=, and WALLTRANSPARENCY= options. The value specified by the TRANSPARENCY= option is only applied to the transparencies that you do not specify individually.
Interaction: In a LAYOUT OVERLAY block, the TRANSPARENCY= option only affects the bars and the data labels. The LAYOUT OVERLAY statement specifies the transparency of the background, grid, and wall of the graph.
WALLTRANSPARENCY= number

specifies the degree of the transparency of the plot wall.

Default: 0
Range: 0 (opaque) to 1 (entirely transparent)
Interaction: The WALLTRANSPARENCY= option overrides the TRANSPARENCY= option for the graph wall.
Interaction: Ignored in a LAYOUT OVERLAY block. For information, see Ignored Plot Options in a LAYOUT OVERLAY Block.
See also: TRANSPARENCY= option
XAXIS= X | X2

specifies whether data is mapped to the primary X axis or to the secondary X (X2) axis.

Default: X
Interaction: Outside of a LAYOUT OVERLAY block, an individual plot can have only one X axis. The XAXIS= option of a plot specifies whether the axis is in the primary (bottom) or secondary (top) position. The XAXISOPTS= option of a plot specifies whether the axis is displayed and specifies the axis characteristics.

Within a LAYOUT OVERLAY block, multiple plots can share a primary axis and a secondary axis. The primary and secondary axes can have different scales, and the XAXIS= option for a particular plot can map data to either axis. The XAXISOPTS= and X2AXISOPTS= options of a LAYOUT OVERLAY statement specify whether the axes are displayed, and specify the axis characteristics.

XAXISOPTS= ( axis-options )

specifies one or more X axis options.

Requirement: The list of axis options must be enclosed in parentheses and separated by spaces.
Interaction: Ignored in a LAYOUT OVERLAY block. For information, see Ignored Plot Options in a LAYOUT OVERLAY Block.
XGRID= boolean

specifies whether the grid lines are drawn at the tick marks.

Default: FALSE
Interaction: Ignored in a LAYOUT OVERLAY block. For information, see Ignored Plot Options in a LAYOUT OVERLAY Block.
Interaction: If you specify or use the default XGRID= option for the OVERLAY LAYOUT statement, then the XGRID= option specified for a graph is ignored. Default characteristics for the grid lines are specified from the following attributes on the GraphGridLines style element:
Color

Foreground

Thickness

LineThickness (default=1 px)

Pattern

LineStyle (default=1)

YAXIS= Y | Y2

specifies whether data is mapped to the primary Y axis or to the secondary Y (Y2) axis.

Default: Y
Interaction: Outside of a LAYOUT OVERLAY block, an individual plot can have only one Y axis. The YAXIS= option of a plot specifies whether the axis is in the primary (left) or secondary (right) position. The YAXISOPTS= option of a plot specifies whether the axis is displayed and specifies the axis characteristics.

Within a LAYOUT OVERLAY block, multiple plots can share a primary axis and a secondary axis. The primary and secondary axes can have different scales, and the YAXIS= option for a particular plot can map data to either axis. The YAXISOPTS= and Y2AXISOPTS= options of a LAYOUT OVERLAY statement specify whether the axes are displayed, and specify the axis characteristics.

YAXISOPTS= ( axis-options )

specifies one or more Y axis options.

Requirement: The list of axis options must be enclosed in parentheses and separated by spaces.
Interaction: Ignored in a LAYOUT OVERLAY block. For information, see Ignored Plot Options in a LAYOUT OVERLAY Block.
YERRORLOWER= numeric-column

specifies the values of the lower endpoints on the Y error bars.

Default: The lower segment of the error bars is not drawn.
Restriction: The YERRORLOWER= option cannot be used with the GROUP= option.
Restriction: The error bar color is a solid black 1 pixel line and cannot be changed.
YERRORUPPER= numeric-column

specifies the values of the upper endpoints on the Y error bars.

Default: The upper segment of the error bars is not drawn.
Restriction: The YERRORUPPER= option cannot be used with the GROUP= option.
Restriction: The error bar color is a solid black 1 pixel line and cannot be changed.
YGRID= boolean

specifies whether grid lines are drawn at the tick marks.

Default: FALSE
Interaction: Ignored in a LAYOUT OVERLAY block. For information, see Ignored Plot Options in a LAYOUT OVERLAY Block.
Interaction: If you specify or use the default YGRID= option for the OVERLAY LAYOUT statement, then the YGRID= option specified for a graph is ignored. Default characteristics for the grid lines are specified from the following attributes on the GraphGridLines style element:
Color

Foreground

Thickness

LineThickness (default=1 px)

Pattern

LineStyle (default=1)


Previous Page | Next Page | Top of Page