l_getSubtitles: Return the subtitles

View source: R/l_getSubtitles.R

l_getSubtitlesR Documentation

Return the subtitles

Description

Return the subtitles

Usage

l_getSubtitles(target)

## S3 method for class 'l_facet_ggplot'
l_getSubtitles(target)

## S3 method for class 'l_facet_wrap'
l_getSubtitles(target)

## S3 method for class 'l_facet_grid'
l_getSubtitles(target)

Arguments

target

an l_facet_ggplot object. If the ggplot object is faceted (either by facet_wrap or facet_grid), an l_facet_ggplot object will be returned once it is turned to a loon plot.

Value

A list of labels, i.e. subtitles, labels, title, etc

Examples

if(interactive()) {
p <- ggplot(mpg, aes(displ, hwy)) +
  geom_point() +
  facet_wrap(vars(class))
lp <- loon.ggplot(p)
l_getSubtitles(lp)
}


loon.ggplot documentation built on Nov. 13, 2022, 1:06 a.m.