backbone: Extract the backbone of a weighted network using the...

Description Usage Arguments Value Author(s) References Examples

Description

Given a weighted graph, backbone identifies the 'backbone structure' of the graph, using the disparity filter algorithm by Serrano et al. (2009).

Usage

1
2
backbone(graph, weights = igraph::E(graph)$weight,
  directed = igraph::is_directed(graph), alpha = 0.05)

Arguments

graph

The input graph.

weights

A numeric vector of edge weights, which defaults to E(graph)$weight.

directed

The directedness of the graph, which defaults to the result of is_directed.

alpha

The significance level under which to preserve the edges, which defaults to 0.05.

Value

An edge list corresponding to the 'backbone' of the graph, i.e. the edges of the initial graph that were preserved by the null model that the disparity filter algorithm implements.

Author(s)

Serrano et al. (2009); R implementation by Alessandro Bessi and Francois Briatte

References

Serrano, M.A., Boguna, M. and Vespignani, A. (2009). Extracting the multiscale backbone of complex weighted networks. Proceedings of the National Academy of Sciences 106, 6483-6488.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
if (require(igraph)) {

  # undirected network
  g <- sample_pa(n = 250, m = 5, directed = FALSE)
  E(g)$weight <- sample(1:25, ecount(g), replace = TRUE)
  backbone(g)
  
  # directed network
  g <- sample_pa(n = 250, m = 5, directed = TRUE)
  E(g)$weight <- sample(1:25, ecount(g), replace = TRUE)
  backbone(g)

}

Example output

Loading required package: igraph

Attaching package: 'igraph'

The following objects are masked from 'package:stats':

    decompose, spectrum

The following object is masked from 'package:base':

    union

    from to weight      alpha
221   48  9     24 0.03811892
368   77  2     25 0.03070550
725  148 23     18 0.03092621
791  162 72     23 0.03714964

disparityfilter documentation built on May 2, 2019, 2:51 p.m.