Description Usage Arguments Details Value Author(s) Examples

Returns the union of the input matrices. Output object is an
adjacency matrix where the edge weight is 1 if an edge is present in both
graphs, 0.5 if present in 1 graph, and 0 if present in neither graph. Edges
in both graphs failing to meet the `cutoff`

, if provided, are set to
zero before performing the graph union.

1 |

`matrix1` |
Square matrix (e.g. correlation or adjacency) containing row/column labels |

`matrix2` |
Square matrix (e.g. correlation or adjacency) containing row/column labels |

`cutoff` |
The cutoff value. Edges less than this value (absolute value considered)are converted to zero. |

`...` |
Other parameters. |

Matrices must be square and have row and column labels. Output adjacency matrix can be used directly for creating a graph object.

`netUnion`

returns an adjacency matrix containing edges present either
both graphs.

Shannon M. Bell

1 2 3 4 5 6 7 8 9 10 11 | ```
#using the state.x77 and USArrest datasets
#remove data from states for illustration
ssArrest<-subset(t(USArrests), select=-c(Alabama,Colorado,Delaware))
ssState<-subset(t(state.x77), select=-c(Alabama, Arizona, Iowa))
arrestCor<-cor(ssArrest)
stateCor<-cor(ssState)
dataUnion<-netUnion(stateCor, arrestCor)
dataUnion[1:15,1:5]
#Setting a cutoff to remove any edges that are below 0.6
dataUnion.6<-netUnion(stateCor, arrestCor, cutoff=0.6)
dataUnion.6[1:15,1:5]
``` |

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.