Skip to main content

Data from: The ecology of spider sociality – A spatial model

Cite this dataset

Vásárhelyi, Zsóka; Scheuring, István; Avilés, Leticia (2021). Data from: The ecology of spider sociality – A spatial model [Dataset]. Dryad.


The emergence of animal societies offers unsolved problems for both evolutionary and ecological studies. Social spiders are specially well suited to address this problem given their multiple independent origins and distinct geographical distribution. Based on long term research on the spider genus Anelosimus, we developed a spatial model that recreates observed macroecological patterns in the distribution of social and subsocial spiders. We show that parallel gradients of increasing insect size and disturbance (rain, predation) with proximity to the lowland tropical rainforest would explain why social species are concentrated in the lowland wet tropics, but absent from higher elevations and latitudes. The model further shows that disturbance, which disproportionately affects small colonies, not only creates conditions that require group living, but also tempers the dynamics of large social groups. Similarly simple underlying processes, albeit with different players on a somewhat different stage, may explain the diversity of other social systems.



This dataset was created by a spatial computer model written in python. The dataset contains the main results, further results can be re-generated by the python code, or its minor variants, available as a supplement of our publication.

The modelled grid incorporates parallel gradients of insect size and disturbance in a square lattice grid, one end of which represents a high elevation tropical cloudforest, the other, a lowland tropical rainforest. As we move from the cloudforest to the rainforest, insects get larger and disturbances more severe. Each node can be inhabited by a single colony of either a subsocial or a social spider species, as inspired by those in the genus Anelosimus.

Usage notes

readme.txt -> help



basic_setting -> the model with the basic parameters

test_preysize_hyp -> test of the prey size hypothesis

test_disturbance_hyp -> test of the disturbance hypothesis

control_preysize_hyp -> control for the prey size hypothesis

control_disturbance_hyp -> control for of the disturbance hypothesis



col_sizes.txt -> records colony sizes at 1 arbitrary position in each environment

data_allsizes -> descriptive statistics for all social colony sizes averaged throughout the last 100 generations

data_social -> descriptive statistics on all social colonies within each generation

data_subsocial -> descriptive statistics on all subsocial colonies within each generation

parameters -> main parameters of the simulation

population -> records the whole grid (both populations) in the last two generations


Hungarian Scientific Research Fund, Award: K128289

Natural Sciences and Engineering Research Council, Award: Canada Discovery Grant NSERC 426

Hungary’s Economic Development and Innovation Operative Program, Award: GINOP 2.3.2-15-2016-00057