draw_prism_bracket: Grob for bracket axes

View source: R/guide_prism_bracket.R

draw_prism_bracketR Documentation

Grob for bracket axes

Description

Grob for bracket axes.

Usage

draw_prism_bracket(
  break_positions,
  break_labels,
  axis_position,
  theme,
  check.overlap = FALSE,
  angle = NULL,
  n.dodge = 1,
  width = NULL,
  outside = TRUE
)

Arguments

break_positions

Position of bracket center and labels

break_labels

Labels between ticks

axis_position

Position of axis (top, bottom, left or right)

theme

A complete theme object

check.overlap

Silently remove overlapping labels, (recursively) prioritizing the first, last, and middle labels.

angle

Compared to setting the angle in theme / element_text, this also uses some heuristics to automatically pick the hjust and vjust that you probably want.

n.dodge

The number of rows (for vertical axes) or columns (for horizontal axes) that should be used to render the labels. This is useful for displaying labels that would otherwise overlap.

width

numeric. Controls the width of the bracket. Try values between 0 and 1.

outside

logical. Default is TRUE and brackets point outwards. If FALSE the bracket crossbar is moved so the ticks appear to point inwards towards the plotting area.


ggprism documentation built on May 29, 2024, 5:59 a.m.