ggBox.plot: Boxplots of Continuous Variable with ggplot2

Description Usage Arguments Author(s) See Also Examples

View source: R/ggBox.plot.R

Description

Create boxplot of data.

Usage

1
2
3
ggBox.plot(data, x, y, facet = NULL, fill = NULL,
	facet.cols = NULL, notched = TRUE, scales = "fixed",
	width = 0.7)

Arguments

data

a dataframe

x

Unquoted variable name. The column in data containing factor whose levels will be plotted on the x-axis.

y

Unquoted variable name. The column in data containing numeric vector whose values will be represented by the boxes.

facet

character vector containing name(s) of one or two additional factors in data by which the plot will be faceted.

fill

a character vector specifying the color of the boxes. Default is gray.

facet.cols

numeric. Number of columns in display of faceted plots.

scales

character vector specifying whether scales should be fixed across facets. Values are "fixed", or "free".

width

numeric. Width of boxes in plots.

...

additional options.

Author(s)

Jason Grafmiller

See Also

ggplot2, geom_boxplot.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
data(brown_genitives)

## plot the distribution of type-token ratios by genre
ggBox.plot(brown_genitives, Genre, TypeTokenRatio)

## plot the distribution of type-token ratios by
## genre and construction type
ggBox.plot(brown_genitives, Genre, TypeTokenRatio,
	facet = "Type")

## plot the distribution of type-token ratios by
## genre, possessor animacy and construction type
ggBox.plot(brown_genitives, Genre, TypeTokenRatio,
	facet = c("PossrAnimacyBin", "Type"))

jasongraf1/JGggplot documentation built on May 29, 2019, 11:43 a.m.