Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

panel_border

Add/remove the panel border in a ggplot2 plot


Description

This function provides a simple way to modify the panel border in ggplot2. It doesn't do anything that can't be done just the same with theme(). However, it saves some typing.

Usage

panel_border(color = "grey85", size = 1, linetype = 1, remove = FALSE, colour)

Arguments

color, colour

The color of the border.

size

Size. Needs to be twice as large as desired outcome when panel clipping is on (the default).

linetype

Line type.

remove

If TRUE, removes the current panel border.


cowplot

Streamlined Plot Theme and Plot Annotations for 'ggplot2'

v1.1.1
GPL-2
Authors
Claus O. Wilke [aut, cre] (<https://orcid.org/0000-0002-7470-9261>)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.