transitive.closure: Transitive closure of a directed acyclic graph (dag)

Description Usage Arguments Value Author(s) Examples

View source: R/mnems.r

Description

Computes the transitive closure of a dag or only of a deletion/addition of an edge

Usage

1

Arguments

g

graph as matrix or graphNEL object

u

index of the parent of an edge (optional)

v

index of the child of an edge (optional)

Value

transitively closed matrix or graphNEL

Author(s)

Martin Pirkl

Examples

1
2
g <- matrix(c(0,0,0,1,0,0,0,1,0), 3)
transitive.closure(g)

mnem documentation built on Nov. 18, 2020, 2 a.m.