BarView: Bar plot

Description Usage Arguments Value Author(s) Examples

View source: R/BarView.R

Description

Bar plot

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
BarView(
  df,
  x = "x",
  y = "y",
  fill = "#FC6665",
  bar.width = 0.8,
  position = "dodge",
  dodge.width = 0.8,
  main = NA,
  xlab = NULL,
  ylab = NA,
  ...
)

Arguments

df

A data frame.

x

A character, specifying the x-axis.

y

A character, specifying the y-axis.

fill

A character, specifying the fill color.

bar.width

A numeric, specifying the width of bar.

position

"dodge" (default), "stack", "fill".

dodge.width

A numeric, set the width in position_dodge.

main

A charater, specifying the figure title.

xlab

A character, specifying the title of x-axis.

ylab

A character, specifying the title of y-axis.

...

Other parameters in geom_bar

Value

An object created by ggplot, which can be assigned and further customized.

Author(s)

Wubing Zhang

Examples

1
2
mdata = data.frame(group=letters[1:5], count=sample(1:100,5))
BarView(mdata, x = "group", y = "count")

Example output



MAGeCKFlute documentation built on Nov. 8, 2020, 5:40 p.m.