Learn R Programming

aniSNA (version 1.1.1)

subsampled_permuted_network_metrics: To generate subsamples of the permuted networks and obtain network metrics of those subsamples

Description

To generate subsamples of the permuted networks and obtain network metrics of those subsamples

Usage

subsampled_permuted_network_metrics(
  networks_list,
  subsampling_proportion = c(0.1, 0.3, 0.5, 0.7, 0.9),
  network_metrics_functions_list = c(edge_density = function(x) igraph::edge_density(x),
    diameter = function(x) igraph::diameter(x, weights = NA), transitivity = function(x)
    igraph::transitivity(x))
)

Value

A list of network metrics of class "Subsampled_Permuted_Network_Metrics". Each element of list is a matrix whose columns correspond to subsampling_proportion and rows correspond to the number of networks in networks_list. The entries of the matrix provide values of the corresponding metric.

Arguments

networks_list

A list of igraph objects obtained by permuting the observed network

subsampling_proportion

A vector depicting the levels (in proportion) at which subsamples to be taken

network_metrics_functions_list

A list consisting of function definitions of the network metrics that the user wants to evaluate. Each element in the list should have an assigned name. Default = c("edge_density" = function(x) igraph::edge_density(x), "diameter" = function(x) igraph::diameter(x, weights = NA), "transitivity" = function(x) igraph::transitivity(x))

Examples

Run this code
# \donttest{
data(elk_2010_permutations)
elk_subsamples_permuted_networks <- subsampled_permuted_network_metrics(elk_2010_permutations)
plot(elk_subsamples_permuted_networks, elk_network_2010)
# }

Run the code above in your browser using DataLab