Skip to content

Commit 304cb90

Browse files
authored
Merge pull request #691 from Axelrod-Python/675
Edit of documentation
2 parents 0bc6ed5 + 20b41cb commit 304cb90

32 files changed

+225
-680
lines changed

axelrod/strategies/axelrod_first.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,11 @@ class Joss(MemoryOnePlayer):
210210
"""
211211
Cooperates with probability 0.9 when the opponent cooperates, otherwise
212212
emulates Tit-For-Tat.
213+
214+
Names:
215+
216+
- Joss [Axelrod1980]_
217+
- Hard Joss [Stewart2012]_
213218
"""
214219

215220
name = "Joss"

axelrod/strategies/grudger.py

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,17 @@
33
C, D = Actions.C, Actions.D
44

55
class Grudger(Player):
6-
"""A player starts by cooperating however will defect if at any point the opponent has defected."""
6+
"""
7+
A player starts by cooperating however will defect if at any point the
8+
opponent has defected.
9+
10+
Names:
11+
12+
- Friedman's strategy: [Axelrod1980]_
13+
- Grudger: [Li2011]_
14+
- Grim: [Berg2015]_
15+
- Grim Trigger: [Banks1980]_
16+
"""
717

818
name = 'Grudger'
919
classifier = {

axelrod/strategies/memoryone.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,15 @@ def strategy(self, opponent):
6868

6969

7070
class WinStayLoseShift(MemoryOnePlayer):
71-
"""Win-Stay Lose-Shift, also called Pavlov."""
71+
"""
72+
Win-Stay Lose-Shift, also called Pavlov.
73+
74+
Names:
75+
76+
- WSLS: [Stewart2012]_
77+
- Win Stay Lose Shift: [Nowak1993]_
78+
- Pavlov: [Kraines1989]_
79+
"""
7280

7381
name = 'Win-Stay Lose-Shift'
7482
classifier = {

axelrod/strategies/titfortat.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,11 @@ class TitForTat(Player):
1212
Note that the code for this strategy is written in a fairly verbose
1313
way. This is done so that it can serve as an example strategy for
1414
those who might be new to Python.
15+
16+
Names
17+
18+
- Rapoport's strategy: [Axelrod1980]_
19+
- TitForTat: [Axelrod1980]_
1520
"""
1621

1722
# These are various properties for the strategy

docs/community.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
.. _community:
2+
13
Community
24
=========
35

docs/index.rst

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -83,10 +83,12 @@ Study the evolutionary process using a Moran process::
8383
As well as this, the library has a growing collection of strategies. The
8484
:ref:`strategies-index` gives a description of them.
8585

86-
For further details there is a library of tutorials available:
86+
For further details there is a library of :ref:`tutorials` available and a
87+
:ref:`community` page with information about how to get support and/or make
88+
contributions.
8789

88-
Tutorials
89-
---------
90+
Table of Contents
91+
-----------------
9092

9193
.. toctree::
9294
:maxdepth: 3

docs/reference/bibliography.rst

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
.. _bibliography:
2+
3+
Bibliography
4+
============
5+
6+
This is a collection of various bibliographic items referenced in the
7+
documentation.
8+
9+
.. [Axelrod1980] Axelrod, R. (1980). Effective Choice in the Prisoner’s Dilemma. Journal of Conflict Resolution, 24(1), 3–25.
10+
.. [Banks1980] Banks, J. S., & Sundaram, R. K. (1990). Repeated games, finite automata, and complexity. Games and Economic Behavior, 2(2), 97–117. http://doi.org/10.1016/0899-8256(90)90024-O
11+
.. [Berg2015] Berg, P. Van Den, & Weissing, F. J. (2015). The importance of mechanisms for the evolution of cooperation. Proceedings of the Royal Society B-Biological Sciences, 282.
12+
.. [Kraines1989] Kraines, D. & Kraines, V. Theor Decis (1989) 26: 47. doi:10.1007/BF00134056
13+
.. [Li2011] Li, J., Hingston, P., Member, S., & Kendall, G. (2011). Engineering Design of Strategies for Winning Iterated Prisoner ’ s Dilemma Competitions, 3(4), 348–360.
14+
.. [Nowak1992] Nowak, M. a., & May, R. M. (1992). Evolutionary games and spatial chaos. Nature. http://doi.org/10.1038/359826a0
15+
.. [Nowak1993] Nowak, M., & Sigmund, K. (1993). A strategy of win-stay, lose-shift that outperforms tit-for-tat in the Prisoner’s Dilemma game. Nature, 364(6432), 56–58. http://doi.org/10.1038/364056a0
16+
.. [Press2012] Press, W. H., & Dyson, F. J. (2012). Iterated Prisoner’s Dilemma contains strategies that dominate any evolutionary opponent. Proceedings of the National Academy of Sciences, 109(26), 10409–10413. http://doi.org/10.1073/pnas.1206569109
17+
.. [Singer-Clark2014] Singer-Clark, T. (2014). Morality Metrics On Iterated Prisoner’s Dilemma Players.
18+
.. [Stewart2012] Stewart, a. J., & Plotkin, J. B. (2012). Extortion and cooperation in the Prisoner’s Dilemma. Proceedings of the National Academy of Sciences, 109(26), 10134–10135. http://doi.org/10.1073/pnas.1208087109
19+
.. [Szabó1992] Szabó, G., & Fáth, G. (2007). Evolutionary games on graphs. Physics Reports, 446(4-6), 97–216. http://doi.org/10.1016/j.physrep.2007.04.004

docs/reference/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,5 @@ Contents:
1212
play_contexts.rst
1313
overview_of_strategies.rst
1414
all_strategies.rst
15+
bibliography.rst
1516
glossary.rst

0 commit comments

Comments
 (0)