label_auto: Non-Overlapping Text Labels

View source: R/plot.R

label_autoR Documentation

Non-Overlapping Text Labels

Description

Optimize the location of text labels to minimize overplotting text.

Usage

label_auto(
  x,
  y = NULL,
  ...,
  labels = seq_along(x),
  segment = FALSE,
  box = FALSE
)

Arguments

x, y

A numeric vector giving the x and y coordinates of a set of points. If y is NULL, an attempt is made to interpret x in a suitable way (see grDevices::xy.coords()).

...

Further arguments to be passed to graphics::text(), particularly, character expansion, cex and color, col.

labels

A character vector or expression specifying the text to be written.

segment

A logical scalar: should segments be drawn?

box

A logical scalar: should a box be drawn underneath labels?

Value

label_auto() is called it for its side-effects.

Note

For internal use only.

Author(s)

N. Frerebeau

See Also

graphics::text()

Other graphic tools: circle(), inch2line(), label_percent()


nfrerebeau/codex documentation built on Feb. 24, 2024, 11:58 a.m.