corLinkcommCentrality {linkcomm} | R Documentation |
Correlation of Community Centrality with Classic Centrality
Description
This function calculates the correlation between the community centrality and classic centrality measures for a set of nodes in a network, and plots a scatterplot of the relationship together with a fitted straight line.
Usage
corLinkcommCentrality(x, centrality = "degree", type = "commweight",
method = "spearman", plot = TRUE, pch = 20, ...)
Arguments
x |
An object of class |
centrality |
A character string naming the classic centrality measure. Can be one of |
type |
A character string naming the type of community centrality. Can be |
method |
A character string naming the correlation method. Can be one of |
plot |
Logical, whether to plot a scatterplot of the relationship, defaults to TRUE. |
pch |
An integer specifying the plot symbol (see |
... |
Additional arguments to be passed to |
Details
The correlation between community centrality and classic centrality measures, such as degree or betweenness, may reveal discrepancies, thereby indicating that community centrality scores provide a unique reflection of node importance.
Value
A correlation coefficient.
Author(s)
Alex T. Kalinka alex.t.kalinka@gmail.com
References
Kalinka, A.T. and Tomancak, P. (2011). linkcomm: an R package for the generation, visualization, and analysis of link communities in networks of arbitrary size and type. Bioinformatics 27, 2011-2012.
See Also
Examples
## Generate graph and extract link communities.
g <- swiss[,3:4]
lc <- getLinkCommunities(g)
## Correlate community centrality with degree centrality.
corLinkcommCentrality(lc)