Skip to main content

Code for: A metapopulation model of social group dynamics and disease applied to Yellowstone wolves

Cite this dataset

Brandell, Ellen E. (2021). Code for: A metapopulation model of social group dynamics and disease applied to Yellowstone wolves [Dataset]. Dryad.



The population structure of social species has important consequences for both their demography and transmission of their pathogens. We develop a new form of metapopulation model that tracks two key components of a species’ social system: average group size and number of groups within a population. While the model is general, we parameterize it to mimic the dynamics of the Yellowstone wolf population and two associated pathogens: sarcoptic mange and canine distemper. In the initial absence of disease, we show that group size is mainly determined by the birth, death rates, and the rates at which groups fission to form new groups. The total number of groups is determined by rates of fission and fusion, as well as upon environmental resources and rates of intergroup aggression. Incorporating pathogens into the models reduces the size of the host population, predominantly by reducing the number of social groups. Average group size responds in more subtle ways: infected groups decrease in size, but uninfected groups may increase when disease reduces the number of groups and thereby reduces intraspecific aggression. Our modeling approach allows for easy calculation of prevalence at multiple scales (within group, across groups, and population level), illustrating that aggregate population-level prevalence can be misleading for group-living species. The model structure is general, can be applied to other social species, and allows for a dynamic assessment of how pathogens can affect social structure and vice versa.



How do social and infectious disease dynamics interact in group-living mammals? A significant cost to group living is increased transmission of pathogens. When a pathogen invades a group, members will be more vulnerable to mortality, Allee effects, and ultimately group extinction. The presence of a pathogen reduces the size of the population by reducing the number of social groups, allowing uninfected groups to grow larger from a reduction in inter-group aggression. Concomitantly, Allee effects are exacerbated in infected groups; this reduces the probability of pathogen persistence as infected groups die out more rapidly. Social structuring changes prevalence across scales and influences pathogen invasion and persistence. The models described here provide a new framework for understanding the dynamics of these interactions.



Here is the R code associated with the paper

Brandell et al. 2021. A metapopulation model of social group dynamics and disease applied to Yellowstone wolves. Proceedings of the National Academy of Sciences.

We provide code for the basic metapopulation models (central_allee.R) and the disease models: susceptible-infected-susceptible (SIS_model.R) and susceptible-infected-recovered (SIR_model.R). We have also included the parameters used (parameters.R) and the wolf count data used in Figure 1 of the main text (wolf_counts.csv). 


United States Geological Survey, Award: G17AC00427

NSF LTREB, Award: DEB-1245373