|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectsoftparsmap.Node
softparsmap.SpeciesNode
softparsmap.SpeciesLeaf
Defines a species leaf in a species tree.
Constructor Summary | |
SpeciesLeaf(DataSource dataSource,
int label)
Constructs a species leaf given a data source and a label. |
Method Summary | |
SpeciesLeaf |
addSequence(EdgeType edgeType,
int leafLabel)
Add a sequence with the the given edge type and label. |
SpeciesLeaf |
addSequence(GeneLeaf leaf)
Adds a given sequence. |
java.util.Set |
getChildren()
Leaves can not have children so if calling this method will throw a FatalException . |
java.util.Set |
getSequences()
Returns the set of gene sequences that belongs to this species. |
static SpeciesLeaf |
nextLeafS(DataSource dataSource)
Returns a species leaf with a unique label. |
static SpeciesLeaf |
nextLeafS(DataSource dataSource,
int seq)
Returns a species leaf with a unique label and with one sequence. |
Node |
pruneOneChildNodes()
Remove all internal nodes with only one child. |
java.lang.String |
toNewick()
Returns the subtree in Newick format. |
Methods inherited from class softparsmap.SpeciesNode |
computeLca, computeLca, getDataSource, getPropertyFile, inferMutation, isBelow, isOnSameRootPath, minimizeMutation, nextNodeS, parseNewick, setPreorder |
Methods inherited from class softparsmap.Node |
addChild, compareTo, equals, findLCA, getLabel, getLeaves, getMap, getNodes, getParent, getRoot, getSplits, hasChildren, hashCode, isBinaryTree, isConsistentWith, isRoot, nextUnique, numChildren, removeChild, setMap, setNextUnique, toString, toStringAll, toStringTable, toStringTree |
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public SpeciesLeaf(DataSource dataSource, int label)
dataSource
- is the data source used to create this leaflabel
- is the label of this species leafMethod Detail |
public static SpeciesLeaf nextLeafS(DataSource dataSource, int seq)
dataSource
- is the data source used to create this leafseq
- is the label of the sequence that will be attached
after creating the new species leaf
public static SpeciesLeaf nextLeafS(DataSource dataSource)
dataSource
- is the data source used to create this leaf
public Node pruneOneChildNodes()
Node
pruneOneChildNodes
in class Node
public java.lang.String toNewick()
SpeciesNode
toNewick
in class SpeciesNode
public java.util.Set getChildren()
FatalException
.
getChildren
in class Node
FatalException
- if called.public java.util.Set getSequences()
GeneLeaf
.GeneLeaf
public SpeciesLeaf addSequence(GeneLeaf leaf)
leaf
- is the sequence that will be added
GeneLeaf
public SpeciesLeaf addSequence(EdgeType edgeType, int leafLabel)
edgeType
- is the edge type of the gene leaf addedleafLabel
- is the label of the new sequence that is added
GeneLeaf
,
EdgeType
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |