Internal API

class Individual.Individual(ID, label)

Abstract representation of an individual in the population.

__init__(ID, label)

Class initializer.

Note

Not to be instantiated by the user directly.

Parameters:
  • ID (int) – unique index for this class instance.

  • label (str) – type label for this individual.

ID

unique index of this class instance.

Type:

int

label

type label of this individual.

Type:

str

AvgBirthPayoff

Average Birth Payoff for this individual.

Type:

float

AvgDeathPayoff

Average Death Payoff for this individual.

Type:

float

BirthFitness

Birth Fitness for this individual.

Type:

float

DeathFitness

Death Fitness for this individual.

Type:

float

property ID

Python getter.

property label

Python getter.

property BirthFitness

Python getter.

property DeathFitness

Python getter.

property AvgBirthPayoff

Python getter.

property AvgDeathPayoff

Python getter.

class CustomExceptions.Error

Base class for other exceptions.

Parameters:

Exception (Exception) – built-in Exception class

class CustomExceptions.IncorrectValueError(parameter, message='Please check the documentation for expected argument values.')

Handling incorrect values of user’s arguments.

Parameters:

Error (Error) – Base class for other exceptions.

__init__(parameter, message='Please check the documentation for expected argument values.')

Class initializer.

Parameters:
  • parameter (str) – parameter name

  • message (str, optional) – error message. Defaults to “Please check the documentation for expected argument values.”.

__str__()

Display the error message.

Returns:

error message

Return type:

str