gg_var: Extract an Axis Variable Name

View source: R/plot.R

gg_varR Documentation

Extract an Axis Variable Name

Description

gg_var() extracts the name of the variable used as the "x" or "y" axis in a ggplot object.

Usage

gg_var(gg_obj, axis = c("x", "y"))

Arguments

gg_obj

A ggplot object

axis

The axis variable to extract

Value

A character vector of length 1 containing the variable name


jesse-smith/coviData documentation built on Jan. 14, 2023, 11:08 a.m.