forester.tools
Class SDIunrooted
java.lang.Object
|
+--forester.tools.SDIunrooted
- public class SDIunrooted
- extends java.lang.Object
- Version:
- 1.031 -- last modified: 12/07/00
- Author:
- Christian M. Zmasek
Method Summary |
int |
getCount()
Returns the number of differently rooted trees with minimal number
of duplications, as determined by method "infer". |
int |
getMinimalDuplications()
Returns the minimal number of duplications, as determined
by method "infer". |
int |
getMinimalMappingCost()
Returns the minimal mapping cost "L", as determined
by method "infer". |
long |
getTimeSumSDI()
Returns the sum of times (in ms) needed to run method infer of class SDI. |
Tree[] |
infer(Tree gene_tree,
Tree species_tree,
boolean minimize_mapping_cost,
boolean minimize_height,
boolean return_trees,
int max_trees_to_return,
boolean use_eulenstein)
Infers gene duplications on a unrooted gene Tree. |
static void |
main(java.lang.String[] args)
Main method for this class. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SDIunrooted
public SDIunrooted()
- Default constructor.
getCount
public int getCount()
- Returns the number of differently rooted trees with minimal number
of duplications, as determined by method "infer".
- Returns:
- number of trees with minimal number of duplications
getMinimalDuplications
public int getMinimalDuplications()
- Returns the minimal number of duplications, as determined
by method "infer".
- Returns:
- number of duplications
getMinimalMappingCost
public int getMinimalMappingCost()
- Returns the minimal mapping cost "L", as determined
by method "infer".
(Last modified: 11/07/00)
- Returns:
- the minimal mapping cost "L"
getTimeSumSDI
public long getTimeSumSDI()
- Returns the sum of times (in ms) needed to run method infer of class SDI.
Final variable TIME needs to be set to true.
- Returns:
- sum of times (in ms) needed to run method infer of class SDI
infer
public Tree[] infer(Tree gene_tree,
Tree species_tree,
boolean minimize_mapping_cost,
boolean minimize_height,
boolean return_trees,
int max_trees_to_return,
boolean use_eulenstein)
throws java.lang.Exception
- Infers gene duplications on a unrooted gene Tree.
If return_trees is set to true, it returns an array of differently
rooted Trees which have the minimal number of duplications. The
maximal number of returned trees is set with max_trees_to_return.
If use_eulenstein is set to true, Eulenstein's algorithm is used,
otherwise Eddy's algorithm for duplication inference is used.
Tree species_tree is a species Tree to which the gene
Tree gene_tree is compared to.
Conditions: Both Trees must be completely binary.
The species Tree must be rooted.
Both Trees must have species names in the species name
field of their Nodes.
(See "TreeHelper.cleanSpeciesNamesInExtNodes" and
and "TreeHelper.extractSpeciesNameFromSPseqName".)
Reference for L. Zhang, L. (1997) On a Mirkin-Muchnik-Smith Conjecture
for Comparing Molecular Phylogenies. Journal of Computational
Biology 4 177-187.
(Last modified: 11/11/00)
- Parameters:
gene_tree
- a unrooted binary (except deepest node)
gene Treespecies_tree
- a rooted binary species Treeminimize_mapping_cost
- set to true to root by minimizing the
mapping cost L, otherwis rooting is
accomplished by minimizing the sum of
duplicationsminimize_height
- set to true to root by minimizing the
tree height of the trees with minimal
duplications or minimal mapping costreturn_trees
- set to true to return Array of Trees,
otherwise null is returnedmax_trees_to_return
- maximal number of Trees to return
(=maximal size of returned Array)
must be no lower than 1; this number
is ignored if the height is being minimizeduse_eulenstein
- set to true to use Eulenstein's algorithm
instead of Eddy's- Returns:
- array of rooted Trees which have the minimal number
of duplications, if return_trees is set to true, null otherwise
main
public static void main(java.lang.String[] args)
- Main method for this class.
(Last modified: 11/11/00)
- Parameters:
[args[
- 0 ] = -e to use Eulenstein's algorithm][args[
- 0 ] = -l to minimize mapping cost L instead of duplications][args[
- 0 ] = -h to minimize height of trees with minimal
duplications or minimal mapping cost]args[
- 0 or 1 ] species-tree file nameargs[
- 1 or 2 ] gene-tree file name