gbarplot: Grid-Based Bar Plots

Description Usage Arguments Author(s) See Also Examples

Description

Creates a bar plot with vertical bars.

Usage

1
2
gbarplot(x, col = 1:4, legend = "NA",
         lsize = unit(0.5, "inches"), ylim = NULL)

Arguments

x

Either a vector or matrix of values describing the bars which make up the plot. If x is a vector, the plot consists of a sequence of rectangular bars with heights given by the values in the vector. If height is a matrix each bar of the plot corresponds to a column of x, with the values in the column giving the heights of stacked sub-bars making up the bar.

col

A vector of colours for the bars or bar components.

legend

A vector of characters for the bar descriptions.

lsize

An integer giving the size of the legend in inches.

ylim

Limits for the y axis.

Author(s)

Ingo Voglhuber

See Also

gmatplot, gpie, gstars, gsymbols, gbxp

Examples

1
2
3
4
5
6
7
8
 grid.newpage()

 gbarplot(c(10,20,50,40), legend=c("black item"))

 grid.newpage()

 gbarplot(cbind(c(10,30),c(40,20)), 
              legend=c("black item","red item"))


Search within the gsymbols package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.