Skip to contents

This geom behaves like ggraph::geom_node_text() except that it also inserts a white background behind the text extending to the left margin. This will only make sense for a horizontal dendrogram graph layout with the root node on the left.

Usage

geom_node_text_filled(
  mapping = NULL,
  data = NULL,
  position = "identity",
  parse = FALSE,
  check_overlap = FALSE,
  show.legend = NA,
  ...
)

Arguments

mapping, data, position, parse, check_overlap, show.legend, ...

Arguments passed to the geom that powers ggraph::geom_node_text(). Note that the additional arguments of that function such as repel are not supported here.

Value

Layer that draws text and background grobs

Details

This background covers up part of the grid rendered by the coord layer. The reason that this is done as part of the text instead of as a separate layer is so that we have access to the rendered dimensions of the text grobs.