Skip to contents

Label links

Usage

pipe_label_links(
  graf,
  field = "link_id",
  fun = "count",
  value = NULL,
  add_field_name = F,
  clear_previous = T
)

Arguments

graf

A mapfile representing a causal map. A mapfile is a tidygraph, which consists of a table of edges linked to a table of nodes, with an optional additional table of statements. In this package, nodes are called `factors` and edges are called `links.`

field

A numerical or character field in the link table.

clear

Logical. Whether to clear any existing labels or to concatenate the new result after any existing labels.

Value

A mapfile with a column `label`. If `clear` is FALSE (the default), the new label is concatenated after any existing label. The new label is of the form `field: value`.