Description Usage Arguments Value Author(s)
This is a encapsulated function to make a boxplot using the ggplot2 package. When parsing a cross-over study or repeated measure data, lines can be drawn between the 2 points belong to the same entity in different timepoints.
1 2 3 4 |
data |
A data.frame containing all the variables needed to draw the box plot. |
x |
A character string indicating the x axis variable. |
y |
A character string indicating the y axis variable. |
cols |
A character string indicating the variable defines faceting groups on columns. |
rows |
A character string indicating the variable defines faceting groups on rows. |
line |
A character string indicating the variable used to draw lines between points. |
color |
A character string indicating the variable defines the color of lines or points. |
show.points |
Logic value indicates whether to show points. |
jitter |
Numeric value defines the amount of horizontal jitter. |
box.size |
Numeric value defines the size of the box. |
whisker.size |
Numeric value defines the size of whisker. |
whisker.width |
Numeric value defines the width of boxplot |
point.size |
Numeric value defines the size of points. |
point.alpha |
Numeric value defines the transparency. |
point.color |
Character value defines the color of points when the argument 'color' is not specified. |
color.pal |
Character vector defines the color panel to use. |
show.legend |
Logic value defines whether to show legend. |
A ggplot object
Chenghao Zhu
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.