topologicalSort: Do a topological sort on a graph

Description Usage Arguments Details Value

Description

Return a linear ordering of vertices in an acyclic directed graph such that for every directed edge from u to v, u comes before v in the ordering.

Usage

1

Arguments

edges

named list of edges from each vertex as character vector

Details

edges list should be named for each vertex in the graph. Each vertex object should be a character vector of vectors to which the vector has a directed edge.

Uses Kahn's algorithm https://en.wikipedia.org/wiki/Topological_sorting#Kahn.27s_algorithm

Value

character vector of sorted vertices


anhinton/conduit documentation built on May 10, 2019, 11:48 a.m.