getLegend: Get Legend of a ggplot.

View source: R/utils.R

getLegendR Documentation

Get Legend of a ggplot.

Description

The function extracts the legend of a ggplot object.

Usage

getLegend(plt)

Arguments

plt

A ggplot object.

Value

The legend of plt or NULL if no legend was found.


pik-piam/mip documentation built on April 13, 2025, 5:45 p.m.