Hide Comments
Hide Comments

Comments (0)

Loads an entire population and their chromosome from the XML parameter. The old population is first cleared.

Namespace: RSGeneticAlgorithm

expandingSyntax

Delphi

public
  procedure LoadFromXML( const ChromosomesXML: IXMLChromosomes ); reintroduce; overload; virtual;
 

Parameters

ChromosomesXML

Type: IXMLChromosomes

expandingExamples

The following example loads the gene descriptions and a representative population from a genetic algorithm domain (read from a file):

Delphi

procedure LoadFromFile(const FileName: string);
 var
   GAXML: IXMLGADomainType;
 begin
      GAXML := LoadGeneticAlgorithm(Filename).Domain;
      RSGeneticAlgorithm1.Genes.LoadFromXML( GAXML.GenoType );
      RSGeneticAlgorithm1.Population.LoadFromXML( GAXML.Chromosomes );
 end;

expandingSee Also

Comments (0)