find_path_one_to_many: Find the a valid path from one node to many

View source: R/find_path.R View source: R/extendr-wrappers.R View source: R/extendr-wrappers.R

find_path_one_to_manyR Documentation

Find the a valid path from one node to many

Description

Find a valid path from one node to many

Usage

find_path_one_to_many(graph, from, to)

Arguments

graph

A graph object

from

The starting node of the path

to

A character vector of nodes

Value

A list of paths

See Also

Other analyze graphs: find_all_paths(), find_path(), get_all_leaves(), get_all_roots(), get_leaves_under(), get_roots_over(), least_common_parents()

Examples

edges <- data.frame(
  parent = c("A", "A", "B", "Z"),
  child =  c("B", "Z", "Z", "F")
)

graph <- graph_builder() |>
  populate_edges(edges, parent, child) |>
  build_acyclic()

find_path_one_to_many(graph, "A", edges$child)

orbweaver documentation built on June 8, 2025, 11:40 a.m.