rm_axis: Remove an axis from a ggplot

View source: R/rm_axis.R

rm_axisR Documentation

Remove an axis from a ggplot

Description

Remove an axis from a ggplot

Usage

rm_axis(axis, line_too = TRUE)

Arguments

axis

The axis to remove ("x" or "y")

line_too

Whether to remove the axis line too (i.e. not just the title, ticks and text)

Examples


data <- tibble::tibble(x = 1:3, z = 3:1)

ggplot2::ggplot(data, ggplot2::aes(x = x, y = x)) +
  ggplot2::geom_line() +
  rm_axis("x")


rscherrer/speciomer documentation built on March 11, 2023, 5:37 p.m.