HSGEP-0.1.0: Gene Expression Programming evolutionary algorithm in HaskellSource codeContentsIndex

This module contains code related to fitness evaluation. The main purpose of the code is to both evaluate fitnesses of individuals and to sort individuals by fitness. These are intended to all be higher order functions that assume nothing about the purpose of the individuals or the types of inputs being used for fitness testing. The only assumption made currently is that the outputs for test cases are floating point numbers. That likely should change for general purpose usage.


fitness_tester :: a -> (a -> b -> Double -> Double -> Double) -> [b] -> [Double] -> Double -> Double
fitness_filter :: [Double] -> [Individual] -> [(Double, Individual)]
sortByFitness :: [(Double, Individual)] -> [(Double, Individual)]
:: aExpressed individual
-> a -> b -> Double -> Double -> DoubleFitness function
-> [b]List of symbol tables for test cases
-> [Double]List of expected outputs for test cases
-> DoubleRange of selection. M in original GEP paper equations for fitness.
-> DoubleFitness value for given individual
Fitness evaluator for generic individuals. This needs to go away and use a more general approach like evaluateFitness above.
:: [Double]Fitness values
-> [Individual]Individuals
-> [(Double, Individual)]Paired fitness/individuals after filtering
Given a list of fitness values and a corresponding list of individuals, return a list of tuples pairing the fitness value with the individuals for only those individuals that have a valid fitness value. This means those that are +/- infinity or NaN are removed.
sortByFitness :: [(Double, Individual)] -> [(Double, Individual)]Source
Sort a set of individuals with fitness values by their fitness
Produced by Haddock version 2.6.1