random.graph: Generate random DAGs

Description Usage Arguments Value

Description

Generate a random graph with fixed number of edges.

Usage

1
2
random.graph(nnode, nedge, acyclic = TRUE, loops = FALSE,
  permute = TRUE)

Arguments

nnode

Number of nodes in the graph.

nedge

Number of edges in the graph.

acyclic

If TRUE, output will be an acyclic graph.

loops

If TRUE, output may include self-loops.

permute

If TRUE, order of nodes will be randomly permuted. If FALSE, output will be ordered according to its topological sort, i.e. with a lower-triangular adjacency matrix.

Value

An edgeList object containing a list of parents for each node.


itsrainingdata/sparsebnUtils documentation built on June 5, 2019, 5:43 p.m.