Package pyrobot :: Package brain :: Module gp :: Class GPGene
[frames | no frames]

Class GPGene

Gene --+
       |
      GPGene


Method Summary
  __init__(self, **args)
  __str__(self)
  crossover(self, parent2, crossoverRate)
Make two new genotypes, or return the old ones.
  display(self)
  eval(self, additionalEnv)
Takes a dictionary...
  mutate(self, mutationRate)
Changes points based on mutationRate.
  replaceTree(self, subtree, temp, replaceChildren)
Replace operator and (optionally) children.
    Inherited from Gene
  __getitem__(self, val)
  __len__(self)
  copy(self)

Method Details

crossover(self, parent2, crossoverRate)

Make two new genotypes, or return the old ones.
Overrides:
pyrobot.brain.ga.Gene.crossover

eval(self, additionalEnv={})

Takes a dictionary

mutate(self, mutationRate)

Changes points based on mutationRate.
Overrides:
pyrobot.brain.ga.Gene.mutate

replaceTree(self, subtree, temp, replaceChildren=1)

Replace operator and (optionally) children.

Generated by Epydoc 2.1 on Mon Jul 25 01:39:26 2005 http://epydoc.sf.net