Evolife
Evolife has been developed to study Genetic algorithms, Natural evolution and behavioural ecology.
Public Member Functions | List of all members
Evolife.Scenarii.CustomScenario.Group Class Reference

Calls local class when creating individuals. More...

Inheritance diagram for Evolife.Scenarii.CustomScenario.Group:
Inheritance graph
[legend]
Collaboration diagram for Evolife.Scenarii.CustomScenario.Group:
Collaboration graph
[legend]

Public Member Functions

def createIndividual (self, ID=None, Newborn=True)
 calls the 'EvolifeIndividual' class calls 'Scenario.new_agent' More...
 
- Public Member Functions inherited from Evolife.Ecology.Group.EvolifeGroup
def createIndividual (self, Newborn=True)
 calls the 'EvolifeIndividual' class calls 'Scenario.new_agent' More...
 
def uploadDNA (self, Start)
 loads given DNAs into individuals More...
 
def update_ (self, flagRanking=False, display=False)
 updates various facts about the group + positions More...
 
def reproduction (self)
 reproduction within the group creates individuals from couples returned by 'Scenario.couples' by calling 'hybrid' on the parents' genome and then by mutating the individual and inserting into the group More...
 
def season (self, year)
 This function is called at the beginning of each year It calls Scenario.season. More...
 
def kill (self, memberNbr)
 kills or weakens one specified individual of the group More...
 
def remove_ (self, memberNbr)
 calls Group.remove_ and also Scenario.remove_agent More...
 
def life_game (self)
 Calls Scenario.life_game. More...
 
def get_average (self)
 computes an average individual in the group More...
 
def get_best (self)
 returns the phenotype of the best or representative individual More...
 
- Public Member Functions inherited from Evolife.Ecology.Group.Group
def __init__ (self, Scenario, ID=1, Size=100)
 
def free_ID (self, Prefix=None)
 returns an available ID More...
 
def createIndividual (self, ID=None, Newborn=True)
 Calls the 'Individual' class. More...
 
def whoIs (self, Number)
 Returns the Numberth individual. More...
 
def isMember (self, indiv)
 
def update_ (self, flagRanking=False, display=False)
 updates various facts about the group More...
 
def statistics (self)
 Updates various statistics about the group. More...
 
def positions (self)
 lists agents' locations More...
 
def season (self, year)
 This function is called at the beginning of each year. More...
 
def kill (self, memberNbr)
 suppress one specified individual of the group More...
 
def remove_ (self, memberNbr)
 tells a member it should die and then removes it from the group More...
 
def remove_member (self, indiv)
 calls 'remove_' with indiv's index in the group More...
 
def extract (self, indiv)
 synonymous to 'remove_member' More...
 
def receive (self, newcomer)
 insert a new member in the group More...
 
def __len__ (self)
 
def __iter__ (self)
 

Additional Inherited Members

- Public Attributes inherited from Evolife.Ecology.Group.Group
 Scenario
 
 size
 
 members
 
 ranking
 
 best_score
 
 ID
 
 location
 
 Examiner
 

Detailed Description

Calls local class when creating individuals.

Definition at line 69 of file CustomScenario.py.

Member Function Documentation

◆ createIndividual()

def Evolife.Scenarii.CustomScenario.Group.createIndividual (   self,
  Newborn = None,
  Newborn = True 
)

calls the 'EvolifeIndividual' class calls 'Scenario.new_agent'

Reimplemented from Evolife.Ecology.Group.EvolifeGroup.

Definition at line 72 of file CustomScenario.py.


The documentation for this class was generated from the following file: