Expand adjacency information to an edge table

Description

Expand adjacency information from an adjacency matrix or a sprof data structure to an edge table

Usage

1
edgedf(data, counts = TRUE, na.rm = TRUE,  no.name="<nn>")

Arguments

data

an adjacency matrix or a sprof data structure.

counts

include a column of counts

na.rm

remove lines with a count NA.

no.name

If not null: replacement for empty strings as name.

Details

The adjacency matrix is flattened. Lines with a count zero are eliminated.

Value

A data frame.

from

Name of from node.

to

Name of to node.

count

optional. Frequencies of edges.

Author(s)

G√ľnther Sawitzki <gsawitzki@users.r-forge.r-project.org>

Examples

1
2

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.