|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Locus
Defines a Locus at which one of several Alleles may appear. The set of
possible alleles is backed by a HashSet so that ordering is not important.
Field Summary | |
---|---|
static java.lang.String |
ID_SEX
|
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 |
Method Summary | |
---|---|
java.lang.String |
add(Allele allele,
int frequency)
Method to add an allele to this locus. |
java.lang.String |
addAllele(Allele allele)
Method to add an allele to this locus. |
Allele |
getAllele(java.lang.String key)
|
java.util.Map<java.lang.String,Allele> |
getAlleleMap()
|
java.util.Collection<Allele> |
getAlleleValues()
|
Chromosome |
getChromosome()
|
java.lang.String |
getKey(Allele allele)
|
Progenitor |
getParent()
|
Locus |
getPolygenic()
|
boolean |
isLegal(java.lang.String allele)
Method to determine if this Locus may contain allele with a non-zero frequency |
Gene |
makeGene(java.lang.String... keys)
Make a gene with the alleles specified by the variable number of allele indexes. |
java.lang.String |
pickAllele()
Method to randomly pick an allele from the set of possible alleles, and chosen according to the frequencies specified for each allele. |
void |
setParent(Progenitor chromosome)
|
int |
size()
|
Methods inherited from interface net.sf.tostring0.IToString |
---|
toString, toStringBrief, toStringId |
Methods inherited from interface net.sf.tostring0.Identifiable |
---|
getIdentifier |
Field Detail |
---|
static final java.lang.String ID_SEX
Method Detail |
---|
java.lang.String add(Allele allele, int frequency)
allele
- An allele which can possibly appear at this locus.frequency
- The relative frequency with which this allele appears at this
locus in the gene pool. This is used when seeding a
population.
java.lang.String addAllele(Allele allele)
allele
- An allele which can possibly appear at this locus.
Allele getAllele(java.lang.String key)
key
-
java.util.Map<java.lang.String,Allele> getAlleleMap()
java.util.Collection<Allele> getAlleleValues()
Chromosome getChromosome()
Chromosome
to which this locus belongs.java.lang.String getKey(Allele allele)
allele
- the key for this allele.
List.indexOf(Object)
on the #list with
the parameter allele. Will return -1 if the allele is not found.Progenitor getParent()
Chromosome
for a non-polygenic locus (or the
first such), otherwise get the polygenic locus which in turn
points to this one.Locus getPolygenic()
boolean isLegal(java.lang.String allele)
allele
- the key to the allele
Gene makeGene(java.lang.String... keys)
keys
- variable number (according to the ploidy) of keys designating
which alleles will make up this locus.
java.lang.String pickAllele()
void setParent(Progenitor chromosome)
chromosome
- int size()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |