View source: R/backbone.extract.R

backbone.extract | R Documentation |

`backbone.extract`

returns a binary or signed adjacency matrix
containing the backbone that retains only the significant edges.

```
backbone.extract(
bb.object,
signed = FALSE,
alpha = 0.05,
mtc = "none",
class = bb.object$class,
narrative = FALSE
)
```

`bb.object` |
backbone: backbone S3 class object. |

`signed` |
boolean: TRUE for a signed backbone, FALSE for a binary backbone (see details) |

`alpha` |
real: significance level of hypothesis test(s) |

`mtc` |
string: type of Multiple Test Correction to be applied; can be any method allowed by |

`class` |
string: the class of the returned backbone graph, one of c("matrix", "sparseMatrix", "igraph", "edgelist"), converted via tomatrix. |

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

The "backbone" S3 class object is composed of (1) the weighted graph as a matrix, (2) upper-tail p-values as a
matrix, (3, if `signed = TRUE`

) lower-tail p-values as a matrix, (4, if present) node attributes as a dataframe, and
(5) several properties of the original graph and backbone model

When `signed = FALSE`

, a one-tailed test (is the weight stronger?) is performed for each edge. The resulting backbone
contains edges whose weights are significantly *stronger* than expected in the null model. When `signed = TRUE`

, a
two-tailed test (is the weight stronger or weaker?) is performed for each edge. The resulting backbone contains
positive edges for those whose weights are significantly *stronger*, and negative edges for those whose weights are
significantly *weaker*, than expected in the null model.

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

.

```
#A binary bipartite network of 30 agents & 75 artifacts; agents form three communities
B <- rbind(cbind(matrix(rbinom(250,1,.8),10),
matrix(rbinom(250,1,.2),10),
matrix(rbinom(250,1,.2),10)),
cbind(matrix(rbinom(250,1,.2),10),
matrix(rbinom(250,1,.8),10),
matrix(rbinom(250,1,.2),10)),
cbind(matrix(rbinom(250,1,.2),10),
matrix(rbinom(250,1,.2),10),
matrix(rbinom(250,1,.8),10)))
backbone.object <- fixedrow(B, alpha = NULL)
bb <- backbone.extract(backbone.object, alpha = 0.05)
```

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.