View source: R/met.disparity.R
met.disparity | R Documentation |
Calculates the node metric disparity for all vertices.
met.disparity(M, df = NULL, dfid = NULL)
M |
a square adjacency matrix, or a list of square adjacency matrices, or an output of ANT functions stat.ds.grp, stat.df.focal, stat.net.lk. |
df |
a data frame of same length as the input matrix or a list of data frames if argument M is a list of matrices or an output of ANT functions stat.ds.grp, stat.df.focal, stat.net.lk. |
dfid |
an integer or a string indicating the column with individual ids in argument df. |
Disparity measures the variation of the weight of a node. This metric compares a node's strength with its degree. It informs on the type of edges a node i has, i.e. few strong edges or many weak edges. Disparity of a vertex i is the sum of the squares of the division between the weigthed edge between node i and j and the met.strength of node i
An integer vector of nodes disparity if argument df is NULL.
A list of integer vectors of nodes disparity if argument M is a list of matrices and if argument df is NULL.
A list of arguments df with a new column for nodes disparity titled 'disparity', if argument df is not NULL.
A list of arguments df with a new column for nodes disparity if 1) argument df is not NULL, 2) argument M is an output from ANT functions stat.ds.grp, stat.df.focal, stat.net.lk for multiple matrices permutations, and 3) argument df is a list of data frames of same length as argument M. The name of the column of each element of the list is adapted according to argument value binary.
Sebastian Sosa, Ivan Puga-Gonzalez.
Barthélemy, M., Barrat, A., Pastor-Satorras, R., & Vespignani, A. (2005). Characterization and modeling of weighted networks. Physica a: Statistical mechanics and its applications, 346(1-2), 34-43.
Whitehead, H. (2009). SOCPROG programs: analysing animal social structures. Behavioral Ecology and Sociobiology, 63(5), 765-778.
Sosa, S. (2018). Social Network Analysis, in: Encyclopedia of Animal Cognition and Behavior. Springer.
met.disparity(sim.m)
head(sim.df)
met.disparity(sim.m,df=sim.df)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.