build_label_grob: Build Label Grob

View source: R/assemble-graphs.R

build_label_grobR Documentation

Build Label Grob

Description

Extracts the necessary information from a ggplot object to convert one of the labels (title, subtitle, caption, or tag) into a textbox_grob.

Usage

build_label_grob(label_type, plot, w = grid::unit(6.5, "in"))

Arguments

label_type

Character scalar giving the label to convert to a grob.

plot

A ggplot graph

w

The width of the plot expressed as a grid unit. Default is ‘unit(6.5, ’in')'.

Value

A textbox_grob from the gridtext package.


kbrevoort/kpbtemplates documentation built on May 31, 2024, 12:29 p.m.