Ma et al.'s extended gravity score is the sum of the immediate neighbors' raw gravity scores: \(G^+(i)=\sum_{j\in N(i)}G(j)\), where \(G(j)=\sum_{l:0<d(j,l)\le r}k_s(j)k_s(l)/d(j,l)^2\). Core numbers and hop distances are calculated on the original simple undirected graph. The radius applies around each neighbor j; it is not a radius around the focal node i. A contribution can therefore reach r+1 hops from i, and paths from a neighbor back to i also contribute.
centrality_extended_gravity(x, gravity_radius = 3, ...)Named numeric vector in input node order.
Network input accepted by centrality.
Nonnegative hop-distance cutoff, default 3. NULL
or infinity includes the entire reachable component. The optional
"auto" setting is a cograph extension: round half the mean
finite positive hop distance to the nearest integer (ties to even),
with minimum one. It is not a parameter rule from Ma et al.
Additional arguments to centrality. With
normalized = TRUE, positive final scores are divided by their
maximum.
Default radius three is the setting used in the original paper. NULL or infinity includes every reachable partner, excluding the gravity source itself. Radius zero and isolates score zero. The outer neighbor sum has no distance penalty. All inner scores remain raw until the final optional max normalization.
Uses the simple undirected unweighted skeleton, with either direction
creating an edge, parallel edges counted once and loops removed. This
projection is a cograph convention for other inputs. Edge weights,
mode, gravity_mass and path-weight inversion do not affect
this measure: its masses are always k-shell indices. Computation includes
all-pairs hop distances, so it can be expensive for large graphs.
Ma, L. L., Ma, C., Zhang, H. F., & Wang, B. H. (2016). Identifying influential spreaders in complex networks based on gravity formula. Physica A, 451, 205-212. tools:::Rd_expr_doi("10.1016/j.physa.2015.12.162").
centrality_gravity.
centrality_extended_gravity(igraph::make_ring(6), gravity_radius = 3)
Run the code above in your browser using DataLab