|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.rapidminer.tools.AbstractObservable<Operator>
com.rapidminer.operator.Operator
com.rapidminer.operator.OperatorChain
com.rapidminer.operator.features.FeatureOperator
com.rapidminer.operator.features.selection.AbstractGeneticAlgorithm
com.rapidminer.operator.features.selection.GeneticAlgorithm
public class GeneticAlgorithm
A genetic algorithm for feature selection (mutation=switch features on and off, crossover=interchange used features).
Selection is done by roulette wheel. Genetic algorithms are general purpose optimization / search algorithms that are
suitable in case of no or little problem knowledge.
A genetic algorithm works as follows
population_size individuals. Each attribute is switched
on with probability p_initializep_mutation and vice versa.p_crossover. The
type of crossover can be selected by crossover_type.population_size individuals at random according to their probability.
| Field Summary | |
|---|---|
static java.lang.String |
PARAMETER_CROSSOVER_TYPE
The parameter name for "Type of the crossover. |
static java.lang.String |
PARAMETER_EXACT_NUMBER_OF_ATTRIBUTES
|
static java.lang.String |
PARAMETER_INITIALIZE_WITH_INPUT_WEIGHTS
|
static java.lang.String |
PARAMETER_MAX_NUMBER_OF_ATTRIBUTES
|
static java.lang.String |
PARAMETER_MIN_NUMBER_OF_ATTRIBUTES
|
static java.lang.String |
PARAMETER_P_CROSSOVER
The parameter name for "Probability for an individual to be selected for crossover. |
static java.lang.String |
PARAMETER_P_INITIALIZE
The parameter name for "Initial probability for an attribute to be switched on. |
static java.lang.String |
PARAMETER_P_MUTATION
The parameter name for "Probability for an attribute to be changed (-1: 1 / numberOfAtt). |
static java.lang.String |
PARAMETER_RESTRICT_NUMBER
|
static java.lang.String |
PARAMETER_USE_EXACT_NUMBER
|
| Fields inherited from class com.rapidminer.operator.features.FeatureOperator |
|---|
PARAMETER_CONSTRAINT_DRAW_RANGE, PARAMETER_DRAW_DOMINATED_POINTS, PARAMETER_MAXIMAL_FITNESS, PARAMETER_NORMALIZE_WEIGHTS, PARAMETER_PLOT_GENERATIONS, PARAMETER_POPULATION_CRITERIA_DATA_FILE, PARAMETER_SHOW_POPULATION_PLOTTER, PARAMETER_SHOW_STOP_DIALOG, PARAMETER_USER_RESULT_INDIVIDUAL_SELECTION |
| Constructor Summary | |
|---|---|
GeneticAlgorithm(OperatorDescription description)
|
|
| Method Summary | |
|---|---|
Population |
createInitialPopulation(ExampleSet es)
Sets up a population of given size and creates ExampleSets with randomly selected attributes (the probability to be switched on is controlled by pInitialize). |
protected PopulationOperator |
getCrossoverPopulationOperator(ExampleSet eSet)
Returns an operator that performs crossover. |
protected PopulationOperator |
getMutationPopulationOperator(ExampleSet eSet)
Returns an operator that performs the mutation. |
java.util.List<ParameterType> |
getParameterTypes()
Returns a list of ParameterTypes describing the parameters of this operator. |
protected ExampleSetMetaData |
modifyInnerOutputExampleSet(ExampleSetMetaData metaData)
Subclasses might override this method in order to change the meta data delivered to the inner operators. |
protected ExampleSetMetaData |
modifyOutputExampleSet(ExampleSetMetaData metaData)
Subclasses might override this method in order to change the final outputed meta data |
| Methods inherited from class com.rapidminer.operator.features.selection.AbstractGeneticAlgorithm |
|---|
getPostEvaluationPopulationOperators, getPostProcessingPopulationOperators, getPreEvaluationPopulationOperators, getPreProcessingPopulationOperators, solutionGoodEnough |
| Methods inherited from class com.rapidminer.operator.features.FeatureOperator |
|---|
createCleanClone, doWork, executeEvaluationProcess, getCheckForMaximum, getExampleSetInput, getPopulation, getPopulationEvaluator, getRandom, runEvaluationProcess, setCheckForMaximum |
| Methods inherited from class com.rapidminer.tools.AbstractObservable |
|---|
addObserver, addObserverAsFirst, fireUpdate, removeObserver |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String PARAMETER_P_INITIALIZE
public static final java.lang.String PARAMETER_P_MUTATION
public static final java.lang.String PARAMETER_P_CROSSOVER
public static final java.lang.String PARAMETER_CROSSOVER_TYPE
public static final java.lang.String PARAMETER_MAX_NUMBER_OF_ATTRIBUTES
public static final java.lang.String PARAMETER_MIN_NUMBER_OF_ATTRIBUTES
public static final java.lang.String PARAMETER_EXACT_NUMBER_OF_ATTRIBUTES
public static final java.lang.String PARAMETER_INITIALIZE_WITH_INPUT_WEIGHTS
public static final java.lang.String PARAMETER_USE_EXACT_NUMBER
public static final java.lang.String PARAMETER_RESTRICT_NUMBER
| Constructor Detail |
|---|
public GeneticAlgorithm(OperatorDescription description)
| Method Detail |
|---|
protected ExampleSetMetaData modifyInnerOutputExampleSet(ExampleSetMetaData metaData)
FeatureOperator
modifyInnerOutputExampleSet in class FeatureOperatorprotected ExampleSetMetaData modifyOutputExampleSet(ExampleSetMetaData metaData)
FeatureOperator
modifyOutputExampleSet in class FeatureOperator
public Population createInitialPopulation(ExampleSet es)
throws OperatorException
createInitialPopulation in class FeatureOperatorOperatorException
protected PopulationOperator getMutationPopulationOperator(ExampleSet eSet)
throws UndefinedParameterError
getMutationPopulationOperator in class AbstractGeneticAlgorithmUndefinedParameterError
protected PopulationOperator getCrossoverPopulationOperator(ExampleSet eSet)
throws UndefinedParameterError
getCrossoverPopulationOperator in class AbstractGeneticAlgorithmUndefinedParameterErrorpublic java.util.List<ParameterType> getParameterTypes()
Operator
getParameterTypes in interface ParameterHandlergetParameterTypes in class AbstractGeneticAlgorithm
|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||