sparsify.with.skeleton: Extract Karger's (1999) skeleton backbone

View source: R/sparsify.R

sparsify.with.skeletonR Documentation

Extract Karger's (1999) skeleton backbone

Description

sparsify.with.skeleton is a wrapper for sparsify() that extracts the skeleton backbone described by Karger (1999), which preserves a specified proportion of random edges. It is equivalent to sparsify(escore = "random", normalize = "none", filter = "proportion", umst = FALSE).

Usage

sparsify.with.skeleton(U, s, class = "original", narrative = FALSE)

Arguments

U

An unweighted unipartite graph, as: (1) an adjacency matrix in the form of a matrix or sparse Matrix; (2) an edgelist in the form of a two-column dataframe; (3) an igraph object.

s

numeric: Proportion of edges to retain, 0 < s < 1; smaller values yield sparser graphs

class

string: the class of the returned backbone graph, one of c("original", "matrix", "Matrix", "igraph", "edgelist"). If "original", the backbone graph returned is of the same class as U.

narrative

boolean: TRUE if suggested text & citations should be displayed.

Value

An unweighted, undirected, unipartite graph of class class.

References

package: Neal, Z. P. (2022). backbone: An R Package to Extract Network Backbones. PLOS ONE, 17, e0269137. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1371/journal.pone.0269137")}

model: Karger, D. R. (1999). Random sampling in cut, flow, and network design problems. Mathematics of Operations Research, 24, 383-413. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1287/moor.24.2.383")}

Examples

U <- igraph::erdos.renyi.game(60, .5)
plot(U) #A dense graph
sparse <- sparsify.with.skeleton(U, s = 0.25, narrative = TRUE)
plot(sparse) #A sparser graph

backbone documentation built on May 29, 2024, 8:03 a.m.