View source: R/network-summary.R
| network_radius | R Documentation |
Computes the radius of a network - the minimum eccentricity across all nodes. The eccentricity of a node is the maximum shortest path distance to any other node. The radius is the smallest such maximum distance.
network_radius(x, directed = NULL, ...)
x |
Network input: matrix, igraph, network, cograph_network, or tna object |
directed |
Logical. Consider edge direction? Default TRUE for directed graphs. |
... |
Additional arguments passed to |
Numeric: the network radius
# Star graph: center has eccentricity 1, leaves have 2, so radius = 1
star <- matrix(c(0,1,1,1, 1,0,0,0, 1,0,0,0, 1,0,0,0), 4, 4)
network_radius(star) # 1
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.