R/no_legend.R

Defines functions no_legend

Documented in no_legend

#' No legend
#'
#' see \href{https://github.com/bansell/tidyExt#tidyext-package}{\strong{tidyExt vignette}}
#'
#' @name no_legend
#' @description Omits ggplot2 legend.
#' @export
#' @examples
#' require(ggplot2)
#' mpg |> ggplot2::ggplot(aes(x=cty,y=hwy)) + geom_point(aes(col=drv)) + no_legend()

no_legend <- function()list(ggplot2::theme(legend.position='none'))
bansell/tidyExt documentation built on July 12, 2024, 12:58 p.m.