bg_layer: Get a ggplot layer for background

View source: R/utils.R

bg_layerR Documentation

Get a ggplot layer for background

Description

Get a ggplot layer for background

Usage

bg_layer(
  data,
  x,
  palette,
  palcolor,
  alpha,
  keep_empty,
  facet_by,
  direction = "vertical"
)

Arguments

data

A data frame

x

A character string specifying the column name of the data frame to plot for the x-axis

palette

A character string specifying the palette to use

palcolor

A character string specifying the color to use in the palette

alpha

A numeric value specifying the transparency of the plot

keep_empty

A logical value indicating whether to keep empty groups

facet_by

A character string specifying the column name(s) of the data frame to facet the plot

direction

A character string specifying the direction for the background

Value

A ggplot layer for background


plotthis documentation built on April 11, 2025, 5:45 p.m.