DOI: 10.6084/m9.figshare.837523
title: Data for the paper, "Evolution of swarming behavior is shaped by how predators attack"

description: All of the data and the IPython Notebook we used to generate figures for our paper, "Evolution of swarming behavior is shaped by how predators attack" are contained in the included 'selfish-herd' directory. ------------------------------------------------------------------------------------------ If you have questions, contact us at: Randal S. Olson (rso@randalolson.com) David B. Knoester (dk@msu.edu) ------------------------------------------------------------------------------------------ RUNNING IPYTHON NOTEBOOK To run our IPython Notebook, you must first download the required packages: * Python<br>* IPython<br>* IPython Notebook<br>* glob<br>* NumPy<br>* SciPy<br>* pandas We recommend downloading the Enthought Python distribution, which has all of the packages you will need. There is a free version for people with an active .edu email here:<br>http://enthought.com/products/edudownload.php or a smaller, free version for those without an active .edu email here:<br>http://enthought.com/products/epd_free.php Once you have installed the required packages, open your terminal and navigate to the eos-predator-confusion directory. Once there, enter the command: ipython notebook --pylab=inline This will open up the IPython Notebook terminal. Select the notebook labeled "Evolution of swarming behavior is shaped by how predators attack." This notebook is entirely interactive, so feel free to explore the data yourself. ------------------------------------------------------------------------------------------ DIRECTORY LABELS Each experiment has its own directory. 'kd' and the number following it represents the predator handling time, while 'np' and the number following it represents the number of predators in the experiment. The directory names are as follows: * swarm-sd30-selfish-herd-artificial-selection-combined-hdaa-and-oa-kd10-akd25-50kgens: Artificial selection experiments with 250 prey that experience both outside attacks and highest-density area attacks. These experiment directories have an 'akd' in the title, which represents the highest-density area attack predator's handling time. * swarm-sd30-selfish-herd-artificial-selection-outside-attack-kd4-50kgens: Artificial selection experiment with 250 prey and outside attacks. * swarm-sd30-selfish-herd-artificial-selection-outside-attack-probdeath-kd4-50kgens: Artificial selection experiment with 250 prey, outside attacks, and density-dependent predation. * swarm-sd30-selfish-herd-artificial-selection-rand-attack-kd4-50kgens: Artificial selection experiment with 250 prey and uniformly random attacks. * swarm-sd30-selfish-herd-artificial-selection-rand-attack-probdeath-kd4-50kgens: Artificial selection experiment with 250 prey, uniformly random attacks, and density-dependent predation. * swarm-sd30-selfish-herd-artificial-selection-randwalk-attack-kd4-50kgens: Artificial selection experiment with 250 prey and random walk attacks. * swarm-sd30-selfish-herd-artificial-selection-randwalk-attack-probdeath-kd4-50kgens: Artificial selection experiment with 250 prey, random walk attacks, and density-dependent predation. * swarm-sd30-selfish-herd-rand-starting-pos-density-dependent-survival-swarmsize100-np4-kd10: Predator-prey coevolution experiment with 100 prey and density-dependent predation. * swarm-sd30-selfish-herd-rand-starting-pos-swarmsize100-np4-kd10: Predator-prey coevolution experiment with 100 prey. ------------------------------------------------------------------------------------------ CSV FILE FORMAT Each csv file is one replicate for that experiment. The number following the word "run" in the csv file name is the random number generator seed for that replicate. e.g., run24LOD.csv has a random number generator seed of 24. In the LOD files, there will be a single entry for each ancestor in the final best swarm agent's LOD. LOD files will be in csv format with the column headers listed at the top. Column headers are in the following order: * generation: the generation the ancestor was born<br>* prey_fitness: the fitness of the ancestor prey<br>* predator_fitness: the fitness of the ancestor predator<br>* num_alive_end: the number of surviving prey at the end of the fitness evaluation<br>* avg_bb_size: the average bounding box size of the swarm during the simulation<br>* var_bb_size: the variance in the bounding box size of the swarm during the simulation<br>* avg_shortest_dist: the average distance from every prey agent to the prey agent closest to it<br>* swarm_density_count: the average number of prey agents within safety distance units of each other<br>* prey_neurons_connected_prey_retina: the number of conspecific sensor neurons that the prey Markov network is connected to<br>* prey_neurons_connected_predator_retina: the number of predator sensor neurons that the prey Markov network is connected to<br>* predator_neurons_connected_prey_retina: the number of prey sensor neurons that the predator Markov network is connected to<br>* num_attacks: the number of attacks the predator made on prey during the simulation ------------------------------------------------------------------------------------------ OTHER FILES Some directories, such as 'swarm-sd30-selfish-herd-rand-starting-pos-swarmsize100-np4-kd10', also have .genome. Generally, we save Markov network files as .genome files. These files contain integer values which encode the Markov network. Other directories, such as 'swarm brains/swarm brains-oa-50kgens/', have .dot files, logic.txt, and minlogic.txt files. DOT files are the picture representations of Markov network structure and connectivity. We recommend using the Graphviz software to view these images. logic.txt files contain the truth table mapping every possible sensory input combination to the corresponding output from aor prey Markov network, as described in the paper. minlogic.txt files contain the truth table and representative logic of the prey Markov network, computed with the 'espresso' logic optimization software. ------------------------------------------------------------------------------------------