Chapter Contents

Previous

Next
%BAR, %BAR2

%BAR, %BAR2



Draws a fillable rectangle with opposing corners at (x1,y1) and (x2,y2).

Variables affected: COLOR, FUNCTION, LINE, STYLE, X, Y
Updates: XLAST, YLAST


Syntax

Syntax

%BAR (x1, y1, x2, y2, color, line, style);
%BAR2(x1, y1, x2, y2, color, line, style, width);

Parameter Description
x1, y1 numeric constants or numeric variable names, the x and y coordinates of the lower-left corner of the bar.
x2, y2 numeric constants or numeric variable names, the x and y coordinates of the upper-right corner of the bar.
color literal; the color of the bar. Color can be any SAS/GRAPH color name and must not be enclosed in quotation marks. Use an asterisk (*) to indicate the previously defined value for color.
line numeric constant or numeric variable name; the direction in which to adjust the outline of the bar. Use line values 1 and 2 to offset a particular bar from an axis or adjoining area. Values for line are
0 draw all edges.
1 vertical adjust.
2 horizontal adjust.
3 draw no edges.

See LINE Values for Bars for representations of LINE values.

style literal; the pattern that fills the bar. Values for style are the following bar or block patterns:
SOLID
S
a solid fill.
EMPTY
E
an empty fill.
style<density> a shaded pattern:

style can be R | X | L

density can be 1...5.

See also the discussion of fill patterns for bars and blocks in VALUE=. Note: All parameters must be expressed as values, not variable names.

width sets the size variable and controls the line thickness of the outline around the bar or polygon.


Chapter Contents

Previous

Next

Top of Page

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