replace_labs: Replace a ggplot2's labels (title, subtitle, and/or caption)...

View source: R/replace_labs.R

replace_labsR Documentation

Replace a ggplot2's labels (title, subtitle, and/or caption) with a given string. Works for regular ggplot2 plots and patchwork plots.

Description

Replace a ggplot2's labels (title, subtitle, and/or caption) with a given string. Works for regular ggplot2 plots and patchwork plots.

Usage

replace_labs(p, labs = list(title = NULL, subtitle = NULL, caption = NULL))

Arguments

p

ggplot2 object

labs

named list of labels to replace; must contain elements named 'title', 'subtitle', and 'caption', and no other elements.


grattan/grattantheme documentation built on June 28, 2023, 1:50 p.m.