template_network | R Documentation |
Taking a egor
object, constructs a
network
object with no edges whose vertices have the
attributes of the egos in the dataset, replicating the egos as needed, and
taking into accounts their sampling weights.
template_network(x, N, scaling = c("round", "sample"), ...)
x |
A |
N |
The target number of vertices the output network should have. |
scaling |
If
|
... |
Additional arguments, currently unused. |
A network
object.
Pavel N. Krivitsky
as.egor.network
, which performs the inverse
operation.
data(faux.mesa.high) summary(faux.mesa.high, print.adj = FALSE) fmh.ego <- as.egor(faux.mesa.high) # Same actor attributes fmh.template <- template_network(fmh.ego, N=network.size(faux.mesa.high)) summary(fmh.template, print.adj = FALSE) # Twice the actors, same distribution fmh2.template <- template_network(fmh.ego, N=2*network.size(faux.mesa.high)) summary(fmh2.template, print.adj = FALSE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.