uncombine_network {ergm.multi}R Documentation

Split up a network into a list of subgraphs

Description

Given a network created by combine_networks(), uncombine_network() returns a list of networks, preserving attributes that can be preserved.

Usage

uncombine_network(
  nw,
  split.vattr = nw %n% ".blockID.vattr",
  names.vattr = nw %n% ".blockName.vattr",
  use.subnet.cache = FALSE
)

Arguments

nw

a network::network created by combine_networks().

split.vattr

name of the vertex attribute on which to split, defaulting to the value of the ".blockID.vattr" network attribute.

names.vattr

optional name of the vertex attribute to use as network names in the output list, defaulting to the value of the ".blockName.vattr" network attribute.

use.subnet.cache

whether to use subnet cache if available; this is only safe to do if the network is not used for its edges but only for its vertex and network attributes.

Value

a list of network::networks containing subgraphs on split.vattr. In particular,

If split.vattr is a vector, only the first element is used and it's "popped".

See Also

split.network()

Examples


data(samplk)

o1 <- combine_networks(list(samplk1, samplk2, samplk3))
image(as.matrix(o1))

ol <- uncombine_network(o1)


[Package ergm.multi version 0.2.1 Index]