Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

plot.pivotr

Plot method for the pivotr function


Description

Plot method for the pivotr function

Usage

## S3 method for class 'pivotr'
plot(
  x,
  type = "dodge",
  perc = FALSE,
  flip = FALSE,
  fillcol = "blue",
  opacity = 0.5,
  ...
)

Arguments

x

Return value from pivotr

type

Plot type to use ("fill" or "dodge" (default))

perc

Use percentage on the y-axis

flip

Flip the axes in a plot (FALSE or TRUE)

fillcol

Fill color for bar-plot when only one categorical variable has been selected (default is "blue")

opacity

Opacity for plot elements (0 to 1)

...

further arguments passed to or from other methods

Details

See Also

pivotr to generate summaries

summary.pivotr to show summaries

Examples

pivotr(diamonds, cvars = "cut") %>% plot()
pivotr(diamonds, cvars = c("cut", "clarity")) %>% plot()
pivotr(diamonds, cvars = c("cut", "clarity", "color")) %>% plot()

radiant.data

Data Menu for Radiant: Business Analytics using R and Shiny

v1.3.12
AGPL-3 | file LICENSE
Authors
Vincent Nijs [aut, cre]
Initial release
2020-11-25

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.