Analysis and Replication of Hemelrijk's DomWorld

This page provides more information about the system we analysed in our paper:
Which in 2011 was updated as a book chapter: It includes code so you can check our replication and watch it run yourself, and a scientific critique of Hemelrijk's theories of social structure and primate dominance.  Briefly, the DomWorld results all hinge on two assumptions:
  1. that there is always at least some chance that any animal in a hierarchy might beat any other animal in a dominance interaction. 
  2. that ranks in the dominance hierarchy change frequently as a consequence of unexpected outcomes from these interactions (low-ranking animals beating high-ranking ones).
Neither of these conditions holds for many if not most varieties of social primates.   

Lehmann replication of DomWorld running in NetLogo

Charlotte Hemelrijk's DomWorld (which she inherited from her supervisor Paulien Hogeweg) is one of the most widely published agent-based models in biology.  Although Hogeweg developed it as part of her research into bee colonies, Hemelrijk has used it to explain dominance interactions and social structure in a variety of species, primarily primates.

Because we were interested in studying primate social structure as well, and because a number of the primatologists we worked with had theories that contradicted the DomWorld model, we decided to analyze it.  We first had to replicate the model, partly because there was no publicly-available version, but also because this is good scientific practice.

Several MSc and undergraduate students at Bath tried to replicate DomWorld from Hemelrijk's papers, but none got quite the same behavior she reported.  Finally a PhD student, Hagen Lehmann, found the missing piece.  He fixed the best replication we had so far (by Jing Jing Andrea Wang), and we  presented the paper at two workshops, and published a paper in a workshop proceedings. 

In that paper, we identified six questions that would test the validity of Hemelrijk's use of DomWorld to describe primate social behaviour.

After the workshop, we were able to visit the laboratory of Bernard Thierry, who helped us answer the questions.  We found several problems with the model.  The most significant is that DomWorld predicts that primates' dominance rank should be in a constant rate of flux.  However, in most primate species, a female's rank is determined entirely by her mother's rank and her birth order relative to her sisters. On very rare occasions an entire matrilinial line will change order, but this is really an exceptional event. This may be a better model of the few species like chimpanzees where females migrate between social groups, but for macaques (a widely-used model genus for studying primate social order) it is not realistic.  In egalitarian macaque species, even changes in male rank happen very infrequently, mostly in response to the aging or migration of males.

On the other hand, we also found that even if these problems were removed from the model, some of the other characteristics (such as its explanation for the spatial location of dominant animals within the troop) still hold.


One problem with code is that the computer systems on which we run it keep changing. Thus the actual code we ran for the results shown in our paper is harder to run now unless you dig up the original research platforms.

Archival Code

Here is the exact code we used for the PTRS-B article.

Current Code

Here is newer code for easier replications.

Related Work

page author: Joanna Bryson 
Page last updated 14 December 2008.
Current Code last updated 6 March 2011 for NetLogo 4.1.1