com.rubecula.darwin.domain.genetics
Class Meiosis_Clone

java.lang.Object
  extended by net.sf.tostring0.AToString
      extended by com.rubecula.darwin.domain.genetics.Meiosis_
          extended by com.rubecula.darwin.domain.genetics.Meiosis_Clone
All Implemented Interfaces:
Meiosis, net.sf.tostring0.Identifiable, net.sf.tostring0.IToString

public final class Meiosis_Clone
extends Meiosis_

This is a null-meiosis implementation which is used for haploid genomics (where meiosis doesn't make sense) but where we still need a way of cloning genomes.

Author:
Robin Hillyard

Field Summary
 
Fields inherited from class com.rubecula.darwin.domain.genetics.Meiosis_
LOG
 
Fields inherited from interface net.sf.tostring0.IToString
ANGBR_OPEN, ANGBRA_CLSE, BRA_CLSE, BRA_OPEN, BRCE_OPEN, BRCS_CLSE, COLON, LIST_SEPARATOR, MAX_ELEMENTS_DEFAULT, S_MT, S_PERCENT, SEPARATOR, SPACE
 
Constructor Summary
Meiosis_Clone(org.apache.commons.math.random.RandomGenerator random)
           
 
Method Summary
 java.lang.String doMeiosis(Gene gene, int index)
          Choose an allele at random for the given locus.
 Genome doMeiosis(Genomic genomic, Genes genes, Chromosome chromosome)
          This method essentially clones the existing set of genes.
 
Methods inherited from class com.rubecula.darwin.domain.genetics.Meiosis_
doMeiosisChromosome, getIdentifier, getRandom
 
Methods inherited from class net.sf.tostring0.AToString
toString, toString, toStringBrief, toStringId
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Meiosis_Clone

public Meiosis_Clone(org.apache.commons.math.random.RandomGenerator random)
Parameters:
random -
Method Detail

doMeiosis

public java.lang.String doMeiosis(Gene gene,
                                  int index)
Description copied from class: Meiosis_
Choose an allele at random for the given locus.

Specified by:
doMeiosis in interface Meiosis
Overrides:
doMeiosis in class Meiosis_
Parameters:
gene - the gene on which we are doing the meiosis.
index - if index >=0 then we use it, otherwise we generate a random number between 0 and the gene's ploidy less one.
Returns:
the key of the allele chosen.
See Also:
Meiosis_.doMeiosis(com.rubecula.darwin.domain.helper.Gene, int)

doMeiosis

public Genome doMeiosis(Genomic genomic,
                        Genes genes,
                        Chromosome chromosome)
This method essentially clones the existing set of genes.

Parameters:
genomic -
genes -
chromosome -
Returns:
a haploid genome with loci corresponding to the chromosome (if given)
See Also:
Meiosis.doMeiosis(com.rubecula.darwin.domain.helper.Genomic, com.rubecula.darwin.domain.helper.Genes, com.rubecula.darwin.domain.helper.Chromosome)


Copyright © 2010 Rubecula Software, LLC. All Rights Reserved.