barGraph: Produce a bar graph

Description Usage Arguments Value See Also Examples

View source: R/barGraph.R

Description

barGraph produces a simple bar graph

Usage

1
2
3
barGraph(x, y, mainTitle = "", xLabel = "", yLabel = "", yType = "int",
  yDigits = 0, barColor = "#009DDC", lineColor = barColor,
  lineWidth = 0, orderBy = NULL, orderDesc = FALSE, horizontal = FALSE)

Arguments

x

character, factor, numeric, logical or Date vector

y

numeric vector

mainTitle

character string; graph title

xLabel

character string; x-axis label

yLabel

character string; y-axis label

yType

character string; y-axis format type; valid values are "int", "dlr" and "pct"

yDigits

non-negative integer value indicating the number of decimal places to show when hovering over the bars

barColor

character string; fill color for bars (valid color)

lineColor

character string; line color (valid color)

lineWidth

non-negative integer value indicating line width (use 0 to omit)

orderBy

a value of NULL (do not order), "x" (order by x) or "y" (order by y)

orderDesc

logical value; when ordering by x or y, order descending?

horizontal

logical value; create a horizontal bar graph?

Value

A plot_ly bar graph using x for the bar labels and y for the heights of the bars

See Also

plot_ly

Examples

1
barGraph(c("giraffes", "orangutans", "monkeys"), c(20, 14, 23))

dnegrey/miscTools documentation built on May 3, 2019, 2:57 p.m.