global | R Documentation |

`global`

extracts the backbone of a weighted network using a global threshold

```
global(
G,
upper = 0,
lower = NULL,
keepzeros = TRUE,
class = "original",
narrative = FALSE
)
```

`G` |
A weighted unipartite graph, as: (1) an adjacency matrix in the form of a matrix or sparse |

`upper` |
real, FUN, or NULL: upper threshold value or function that evaluates to an upper threshold value. |

`lower` |
real, FUN, or NULL: lower threshold value or function that evaluates to a lower threshold value. |

`keepzeros` |
boolean: TRUE if zero-weight edges in |

`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 |

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

The `global`

function retains a edge with weight `W`

if `W`

> `upper`

. If a `lower`

threshold is also
specified, it returns a signed backbone in which an edge's weight is set to 1 if `W`

> `upper`

,
is set to -1 if `W`

< `lower`

, and is set to 0 otherwise. The default is an unsigned backbone containing
all edges with non-zero weights.

If `G`

is an unweighted bipartite graph, the global threshold is applied to its weighted bipartite projection.

Binary or signed backbone graph of class given in parameter `class`

.

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: Neal, Z. P. (2014). The backbone of bipartite projections: Inferring relationships from co-authorship, co-sponsorship, co-attendance, and other co-behaviors. *Social Networks, 39*, 84-97. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1016/j.socnet.2014.06.001")}

```
G <- matrix(sample(0:5, 100, replace = TRUE), 10) #Random weighted graph
diag(G) <- 0
G
global(G, narrative = TRUE) #Keep all non-zero edges
global(G, upper = 4, lower = 2, narrative = TRUE) #Signed with specified thresholds
global(G, upper = function(x)mean(x), #Above-average --> positive edges
lower = function(x)mean(x), narrative = TRUE) #Below-average --> negative edges
```

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.