Reproduce the Axelrod iterated prisoners dilemma tournament
A Python library with the following principles and goals:
- Enabling the reproduction of previous Iterated Prisoner’s Dilemma research as easily as possible.
- Creating the de-facto tool for future Iterated Prisoner’s Dilemma research.
- Providing as simple a means as possible for anyone to define and contribute new and original Iterated Prisoner’s Dilemma strategies.
- Emphasizing readability along with an open and welcoming community that is accommodating for developers and researchers of a variety of skill levels.
With Axelrod you:
have access to over 200 strategies, including original and classics like Tit For Tat and Win Stay Lose Shift. These are extendable through parametrization and a collection of strategy transformers.
can create head to head matches between pairs of strategies.
can create tournaments over a number of strategies.
can analyse detailed results of tournaments and matches.
can visualise results of tournaments.
The library has 100% test coverage and is extensively documented. See the documentation for details and examples of all the features: http://axelrod.readthedocs.org/
An open reproducible framework for the study of the iterated prisoner’s dilemma: a peer reviewed paper introducing the library (22 authors).
The library requires Python 3.6 or greater.
The simplest way to install is:
$ pip install axelrod
To install from source:
$ git clone https://github.com/Axelrod-Python/Axelrod.git $ cd Axelrod $ python setup.py install
The following runs a basic tournament:
>>> import axelrod as axl >>> players = [s() for s in axl.demo_strategies] # Create players >>> tournament = axl.Tournament(players, seed=1) # Create a tournament >>> results = tournament.play() # Play the tournament >>> results.ranked_names ['Defector', 'Grudger', 'Tit For Tat', 'Cooperator', 'Random: 0.5']
- https://github.com/Axelrod-Python/tournament is a tournament pitting all the strategies in the repository against each other. These results can be easily viewed at http://axelrod-tournament.readthedocs.org.
- https://github.com/Axelrod-Python/Axelrod-notebooks contains a set of example Jupyter notebooks.
- https://github.com/Axelrod-Python/Axelrod-fingerprint contains fingerprints (data and plots) of all strategies in the library.
All contributions are welcome!
You can find helpful instructions about contributing in the documentation: http://axelrod.readthedocs.org/en/latest/tutorials/contributing/index.html
You can find a list of publications that make use of or cite the library on the citations page.
Release history Release notifications | RSS feed
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
|Filename, size||File type||Python version||Upload date||Hashes|
|Filename, size Axelrod-4.10.0-py2.py3-none-any.whl (193.2 kB)||File type Wheel||Python version 3.7||Upload date||Hashes View|
|Filename, size Axelrod-4.10.0.tar.gz (202.3 kB)||File type Source||Python version None||Upload date||Hashes View|
Hashes for Axelrod-4.10.0-py2.py3-none-any.whl