Table of Contents

Name

barplot - draw a bar graph of ERP data

Synopsis

barplot plot_device cmdfile

Description

barplot is a program which draws bar graphs on a graphics device (plot_device) according to specifications in cmdfile. Barplot allows multiple groups of data to be displayed and labeled, with bars within each group having arbitrary colors and/or fill textures. Legends can be specified for each type of bar within groups, and standard errors or deviations can be optionally plotted at the top of each bar. The ordinate axis can be labelled, and arbitrary margins can be requested for the top, bottom, left, and right sides of the page. The specifications have a particular syntax and format which is described in the barplot user’s manual.

The available graphics devices are:

vid - color video monitor, landscape mode

pvid - color video monitor, portrait mode
las - Laserjet printer, landscape mode
plas - Laserjet printer, portrait mode
hlas - Laserjet printer, landscape mode, high resolution
phlas - Laserjet printer, portrait mode, high resolution
hp - HP pen plotter, landscape mode
php - HP pen plotter, portrait mode
hps - HP pen plotter, landscape mode, slow drawing speed
phps - HP pen plotter, portrait mode, slow drawing speed

Command File Syntax

The following is a brief description of the command file syntax. See the "Barplot Manual" for a more detailed description.

There
are two commands that must appear in the cmdfile, and they must appear before any other commands. These are the group and bar commands. This syntax requirement is related to the implicit nature of the plots produced by barplot. Data is usually displayed along one factor dimension at various levels of another experimental variable or factor. The cmdfile starts with a group statement and its label which will be plotted under the group of bars whose specifications follow that group statement. Following each group statement is one or more bar statements to be grouped together for that group. After all the group and bar statements of other statements can be given for plotting things like legends. The syntax for the group and bar statements is:

group group_label [font] [textsize] [color] [linethickness]

bar bar_value [filltype] [color] [linethickness] [barlabel]

The parameters enclosed in square brackets are optional, and
can appear in any order. They are specified as follows:

font - one of simplex, duplex, complex, or italic.

textsize - textsize=n, where n is a positive number (can have
a decimal point). Note that no spaces are allowed between
"textsize", "=", and "n".

color - color=n, where n is a positive integer, which is
device dependent (on monochrome devices, 0 is invisible, 1 is
that devices color).

linethickness - one of verythin, thin, medium, thick, or verythick.

filltype - fill=n. Fill patterns are number 0 - 43, and can
be seen with the fillpats program. Note that no spaces are
allowed between "fill", "=", and "n".


barlabel - lab="mylabel"

The following is a brief description of the rest of the commands that can be used in a command file. Optional parameters are enclosed in brackets.

axis [color] [linethickness]
Specify the color and/or linethickness of the axis.

barlabelstyle [font] [textsize] [color] [linethickness] [labelpos]
Specify the attributes used for plotting bar labels from
subsequent bar statements. labelpos is specified as
labpos=n, where n is a value on the vertical axis that
determines where bar labels will occur vertically.

barspace space_width
Specify the inter-bar spacings as a fraction of the width
of the plotting page.

barwidth width
Specify the width of the bars in the plot as a fraction
of the width of the plotting page. On the laserjet, you
have an 8 inch wide page, so .10 would be .8 inches wide.

bmargin bottom_margin_width
tmargin top_margin_width
lmargin left_margin_width
rmargin right_margin_width
Specify the margins as a fraction of the width or height of
the plotting page.
       
gborder [color] [linethickness]
Put a border around the graph region of the plot.

header "label" [+] [font] [textsize] [ color] [linethickness]
Label the top of the page with "label". Default is to
center over the page, use of the optional ’+’ centers the
"label" over the graph part of the page.

lheader "label" [+] [font] [textsize] [color] [linethickness]
Like header command only "label" is left-justified
instead of centered.

legend "label" [fill] [font] [textsize] [color] [linethickness]
A small segment of a bar with the specified fill type
along with "label" is plotted near the top of the page.
The position is determined by the number of legends in
the command file.

nyticks number_y_tickmarks
Specifies the number of tickmarks to put on the y axis.
Defaults to 11.

sborder [color] [linethickness]
Put a border around the entire printing region.

text "text_string" x_coord y_coord [font] [textsize] [color] [linethickness]
Plot "text_string" centered at the specified coordinate.
Coordinates are specified as fractional parts of plotting
page width and height.

tickformat "format" number_chars [font] [textsize] [color] [linethickness]
Specify format for tickmark labels on the y axis.
"format" is C style, and defaults to "%6.1f" which means
to that labels should be six characters long (minimum)
with one digit after the decimal point. number_chars is
implicit in "format" but must be specified anyway.

vtext "text_string" x_coord y_coord [font] [textsize] [color] [linethickness]
Plot "text_string" vertically at x_coord y_coord.
Coordinates are specified as fractions of plotting page
width and height.

xlabel "label" [font] [textsize] [color] [linethickness]
Put "label" centered underneath the bargraph.

ylabel "label" [font] [textsize] [color] [linethickness]
Labels the ordinate axis with "label".

ymax maximum_y_axis_value
Specifies the value at the top of the ordinate axis.

ymin minimum_y_axis_value
Specifies value at bottom of the ordinate axis.


Files

c:\tcplotdevs plotting device data base and filter information

See Also

"Barplot User’s Manual"

Diagnostics

barplot prints an extended message, the line number, and the keyword where the error occurred.

Author

Ronald Ohst


Table of Contents