SelectionFunction (BioJava-1.5-beta API)
Keywords: org.biojavax.ga.functions.SelectionFunction interface

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.biojavax.ga.functions
Interface SelectionFunction

All Known Implementing Classes:
  AbstractSelectionFunction, ProportionalSelection, SelectionFunction.SelectAll, SelectionFunction.Threshold

    public interface SelectionFunction

Selects Organisms for Replication and returns the offspring.

Since:
  1.5
Version:
  1.0
Author:
  Mark Schreiber

Nested Class Summary
`static class` | `SelectionFunction.SelectAll`
`static class` | `SelectionFunction.Threshold` Selects individuals who's fitness exceeds a threshold value.

Field Summary
`static SelectionFunction` | `DEFAULT` Selects all members of a population for replication
`static ChangeType` | `FITNESS_FUNCTION`

Method Summary
`FitnessFunction` | `getFitnessFunction()`
`Population` | `select(Population pop, GeneticAlgorithm genAlg)` Selects a `Population` of `Organisms` for replication based on their fitness.
`void` | `setFitnessFunction(FitnessFunction func)` The fitness function that will be used by the select method.

Field Detail

### DEFAULT

    static final SelectionFunction DEFAULT

  Selects all members of a population for replication

### FITNESS_FUNCTION

    static final ChangeType FITNESS_FUNCTION

Method Detail

### select

    Population select(Population pop,
                      GeneticAlgorithm genAlg)
                      throws ChangeVetoException

  Selects a `Population` of `Organisms` for replication based on their fitness.

  Parameters:
    `pop` - the `Population` to select from.
    `genAlg` - the parent `GeneticAlgorithm`.
  Returns:
    the `Organism`s selected
  Throws:
    `ChangeVetoException` - if the function attempts to change the population and it is vetoed.

### setFitnessFunction

    void setFitnessFunction(FitnessFunction func)
                            throws ChangeVetoException

  The fitness function that will be used by the select method.

  Parameters:
    `func` - the `FitnessFunction` to be used
  Throws:
    `ChangeVetoException` - if the change is vetoed.

### getFitnessFunction

    FitnessFunction getFitnessFunction()

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD