Structural models
Random model
The Erdős–Rényi random graph model (Erdős and Rényi 1959) uniformly at random assigns an \(L\) number of links to an \(S\) number of nodes (species richness). From an ecological perspective this model assumes that the interactions between species occurs regardless of the identity of the species (i.e., species have no agency) and links are randomly distributed throughout the network. This creates a food web that is as free as possible from biological structuring while maintaining the expected richness (\(S\)) and connectance (\(L/S^2\))
We could theoretically use the other ‘null models’ BUT I feel like in the context of constructing a network for a given community the Erdős–Rényi is the better choice than the other models that (IMO) are more suited to hypothesis testing e.g. do observed networks differ from the null network… Whereas Erdős–Rényi really is just a case of here is a truly random network with the specified number of links and nodes and anyway one of the Null models is a derivative of Erdős–Rényi if I remember correctly.
Niche model
The niche model (Williams and Martinez 2000) introduces the idea that species interactions are based on the ‘feeding niche’ of a species. Broadly, all species are randomly assigned a ‘feeding niche’ range and all species that fall in this range can be consumed by that species (thereby allowing for cannibalism). The niche of each species is randomly assigned and the range of each species’ niche is (in part) constrained by the specified connectance (\(Co\)) of the network. The niche model has also been modified, although it appears that adding to the ‘complexity’ of the niche model does not improve on its ability to generate a more ecologically ‘correct’ network (Williams and Martinez 2008).
Each of \(S\) species assigned a ‘niche value’ parameter \(n_i\) drawn uniformly from the interval [0,1]. Species \(i\) consumes all species falling in a range (\(r_i\)) that is placed by uniformly drawing the center of the range (\(c_i\)) from \([ \frac{r_i}{2}, n_i ]\) The size of \(r_i\) is assigned by using a beta function to randomly draw values from [0,1] whose expected value is \(2 \times Co\) and then multiplying that value by \(n_i\) to obtain the desired \(Co\).
Allometric diet breadth model
The Allometric diet breadth model (ADBM; Petchey et al. (2008)) is rooted in feeding theory and allocates the links between species based on energetics, which predicts the diet of a consumer based on energy intake. This means that the model is focused on predicting not only the number of links in a network but also the arrangement of these links based on the diet breadth of a species, where the diet (\(K\)) is defined as follows:
\[ K = \frac{\sum_{i=1}^{k}\lambda_{ij}E_{i}}{1+\sum_{i=1}^{k}\lambda_{ij}H_{ij}} \]
where \(\lambda_{ij}\) is the handling time, which is the product of the attack rate \(A_{i}\) and resource density \(N_{i}\), \(E_{i}\) is the energy content of the resource and \(H_{ij}\) is the ratio handling time, with the relationship being dependent on the ratio of predator and prey bodymass as follows:
\[ H_{ij} = \frac{h}{b - \frac{M_{i}}{M_{j}}} if \frac{M_{i}}{M_{j}} < b \]
or
\[ H_{ij} = \infty \geq b \]
Refer to Petchey et al. (2008) for more details as to how these different terms are parametrised.
L matrix
For now we can link to the ATNr package (Gauzens et al. 2023) until I can find a more suitable manuscript that breaks down this construction method. Schneider et al. (2016) Interactions are determined by allometric rules (ratio of consumer (\(M_{i}\)) and resource (\(M_{j}\)) body sizes) and a Ricker function as defined by \(R_{opt}\) and \(\gamma\) and returns The probability of a link (\(P_{ij}\)) existing between a consumer and resource, and is defined as follows:
\[ P_{ij} = (L \times \exp(1 - L))^{\gamma} \]
where
\[ L = \frac{M_{i}}{M_{j} \times R_{opt}} \]
It is also possible to apply a threshold value to \(P_{ij}\), whereby any probabilities below that threshold are set to zero.
Note that as for the ADBM we specify which species are considered to be ‘producer’ species.
Interaction predictions
Paleo food web inference model
The Paleo food web inference model (PFIM; Shaw et al. (2024)) uses a series of rules for a set of trait categories (such as habitat and body size) to determine if an interaction can feasibly occur between a species pair. If all conditions are met for the different rule classes then an interaction is deemed to be feasible. The original work put forward in Shaw et al. (2024) also includes a ‘downsampling’ step developed by Peter D. Roopnarine (2006) that uses a power law, defined by the link distribution, to ‘prune’ down some of the links. It is worth mentioning that this approach is similar to that developed by Peter D. Roopnarine (2017) with the exception that Shaw et al. (2024) does not specifically bin species into guilds, and so we choose to use the method developed by Shaw et al. (2024) since both approaches should produce extremely similar networks as they are built on the same underlying philosophy.
Body size ratio model
The body size ratio model (Rohr et al. 2010) determines the probability of feeding interactions occurring between species by using the ratio between the consumer (\(M_{i}\)) and resource (\(M_{j}\)) body sizes. In order to represent the predator-prey bodymass ratio as a ‘feeding niche’ the ratio is also modified by both a \(\beta\) and \(\gamma\) distribution. The probability of a link existing between a consumer and resource (in its most basic form) is defined as follows:
\[ P_{ij} = \frac{p}{1+p} \]
where
\[ p = exp[\alpha + \beta log(\frac{M_{i}}{M_{j}}) + \gamma log^{2}(\frac{M_{i}}{M_{j}})] \] {#eq-bodymass}
The original latent-trait model developed by Rohr et al. (2010) also included an additional latent trait term \(v_{i} \delta f_{j}\) however for simplicity we will use (eq-bodymass?) as per Yeakel et al. (2014) . Based on Rohr et al. (2010) it is possible to estimate the parameters \(\alpha\), \(\delta\), and \(\gamma\) using a GLM but we will use the parameters from Yeakel et al. (2014), which was ‘trained’ on the Serengeti food web data and are as follows: \(\alpha\) = 1.41, \(\delta\) = 3.75, and \(\gamma\) = 1.87.