forester v1.3

forester.tools
Class SDIunrooted

java.lang.Object
  |
  +--forester.tools.SDIunrooted

public class SDIunrooted
extends java.lang.Object

Version:
1.010 -- last modified: 10/18/00
Author:
Christian M. Zmasek

Constructor Summary
SDIunrooted()
          Default constructor.
 
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.
 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 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
 

Constructor Detail

SDIunrooted

public SDIunrooted()
Default constructor.
Method Detail

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

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 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 our algorithm is used. Tree species is a species Tree to which the gene Tree gene is compared to. Conditions: Both Trees must be completely binary. The species Tree must be rooted. Species found in gene Tree must be a subset of those found in species Tree. Both Trees must have species names in the species name field of their Nodes. (See "TreeHelper.cleanSpeciesNamesInExtNodes" and and "TreeHelper.extractSpeciesNameFromSPseqName".)
Parameters:
gene_tree - a unrooted binary (except deepest node) gene Tree
species_tree - a rooted binary species Tree
return_trees - set to true to return Array of Trees, otherwise null is returned
max_trees_to_return - maximal number of Trees to return (=maximal size of returned Array) must be no lower than 1
use_eulenstein - set to true to use Eulenstein's algorithm
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.
Parameters:
[args[ - 0 ] = -e to use Eulenstein's algorithm]
args[ - 0 or 1 ] species-tree file name
args[ - 1 or 2 ] gene-tree file name

forester v1.3