View source: R/network-summary.R
| trophic_incoherence | R Documentation |
The trophic incoherence parameter q is a measure of how "vertically
ordered" a directed network is (Johnson et al. 2014). For each edge
(u, v), the trophic difference is x_{uv} = s_v - s_u where
s_i is the trophic level of node i. The trophic incoherence
parameter is the (population) standard deviation of these differences:
q = \sqrt{\frac{1}{|E|} \sum_{(u,v) \in E} (x_{uv} - \bar{x})^2}
trophic_incoherence(x, cannibalism = TRUE)
x |
Directed network input. |
cannibalism |
Logical. If |
Low values (q \approx 0) indicate a perfectly coherent network
(e.g., a pure food web where every edge goes up one level). High values
indicate an incoherent network with many level-skipping or downward
edges. Johnson et al. 2014 showed that low-q food webs are
dynamically more stable.
Matches networkx.trophic_incoherence_parameter at machine epsilon.
Directed-only; requires at least one basal node (node with no incoming
edges) for trophic levels to be well-defined.
A single numeric value (NA_real_ for empty edge sets or
undirected input).
Johnson, S., Dominguez-Garcia, V., Donetti, L., & Munoz, M. A. (2014). Trophic coherence determines food-web stability. PNAS, 111(50), 17923-17928.
centrality (the trophic_level measure) for
the per-node levels used in the incoherence calculation.
# Small directed 3-node chain: 1 -> 2 -> 3 (perfectly coherent, q = 0)
adj <- matrix(c(0,1,0, 0,0,1, 0,0,0), 3, 3, byrow = TRUE)
rownames(adj) <- colnames(adj) <- c("A", "B", "C")
trophic_incoherence(adj)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.