Skip to main content
  • Home
  • Development
  • Documentation
  • Donate
  • Operational login
  • Browse the archive

swh logo
SoftwareHeritage
Software
Heritage
Archive
Features
  • Search

  • Downloads

  • Save code now

  • Add forge now

  • Help

https://github.com/reneniehus/bact_warfare
25 August 2023, 07:52:34 UTC
  • Code
  • Branches (1)
  • Releases (0)
  • Visits
    • Branches
    • Releases
    • HEAD
    • refs/heads/master
    No releases to show
  • c60dd23
  • /
  • README.md
Raw File Download
Take a new snapshot of a software origin

If the archived software origin currently browsed is not synchronized with its upstream version (for instance when new commits have been issued), you can explicitly request Software Heritage to take a new snapshot of it.

Use the form below to proceed. Once a request has been submitted and accepted, it will be processed as soon as possible. You can then check its processing state by visiting this dedicated page.
swh spinner

Processing "take a new snapshot" request ...

Permalinks

To reference or cite the objects present in the Software Heritage archive, permalinks based on SoftWare Hash IDentifiers (SWHIDs) must be used.
Select below a type of object currently browsed in order to display its associated SWHID and permalink.

  • content
  • directory
  • revision
  • snapshot
origin badgecontent badge Iframe embedding
swh:1:cnt:8a3b43c5fa96904eef5ae22394c47f82f7d742b6
origin badgedirectory badge Iframe embedding
swh:1:dir:c60dd23f7004bca655d5420d5ac0c7fc4b795c93
origin badgerevision badge
swh:1:rev:923e104aa634230547ba464c6bc8fee07f662ffa
origin badgesnapshot badge
swh:1:snp:a076335e29e65fe4712624d803de7bfaacbf821b
Citations

This interface enables to generate software citations, provided that the root directory of browsed objects contains a citation.cff or codemeta.json file.
Select below a type of object currently browsed in order to generate citations for them.

  • content
  • directory
  • revision
  • snapshot
Generate software citation in BibTex format (requires biblatex-software package)
Generating citation ...
Generate software citation in BibTex format (requires biblatex-software package)
Generating citation ...
Generate software citation in BibTex format (requires biblatex-software package)
Generating citation ...
Generate software citation in BibTex format (requires biblatex-software package)
Generating citation ...
Tip revision: 923e104aa634230547ba464c6bc8fee07f662ffa authored by Rene Niehus on 03 March 2020, 02:26:02 UTC
Update invasion_analysis.m
Tip revision: 923e104
README.md
This folder contains MATLAB and R code to reproduce results from Niehus et al. "The Evolution of Strategy in Bacterial Warfare".

In particular, the file invasion_analysis.m implements an invasion analysis according to classic game theory (see for example McElreath, R. & Boyd, R. Mathematical Models of Social Evolution. Mathematical Models of Social Evolution (2013)). It assumes a monomorphic metapopulation where repeatedly rare mutants appear, and for each mutant it is tested whether it can or cannot invade. This pairwise invasibility algorithm is efficient in finding the optimal constitutive strategy. It follows the pseudocode shown in Supplementary Methods and Results of Niehus et al.

The function mass_battle.m implements the co-evolutionary tournament described in Niehus et al. (see Methods) and that leads to Figure 4. It allows for a polymorphic metapopulation where all three sensing strategies meet and compete in 1-on-1 competitions. Mutation, migration and selection at the meta-population level is at work to establish the long-term winner of this evolutionary race. Note that this script can run up to hours, and that the control parameters can be tuned to improve convergence speed.

The R file vis_mass_batt_fig4c.R loads the results of mass_battle.m and plots them just like in Figure 4 c, allowing to inspect convergence and dominating strategies.

Software Heritage — Copyright (C) 2015–2025, The Software Heritage developers. License: GNU AGPLv3+.
The source code of Software Heritage itself is available on our development forge.
The source code files archived by Software Heritage are available under their own copyright and licenses.
Terms of use: Archive access, API— Contact— JavaScript license information— Web API

back to top