forester v1.3

forester.tools
Class SDI

java.lang.Object
  |
  +--forester.tools.SDI
Direct Known Subclasses:
SDIoe, SDIse

public abstract class SDI
extends java.lang.Object

Version:
1.002 -- last modified: 10/12/00
Author:
Christian M. Zmasek

Constructor Summary
SDI(Tree gene_tree, Tree species_tree)
          Constructor.
 
Method Summary
abstract  int infer(boolean strip_species_tree)
          Abstract method.
static void main(java.lang.String[] args)
          A "main method" for SDI (Speciation versus Duplication Inference).
static int stripTree(Tree reference, Tree to_be_stripped)
          Removes from Tree to_be_stripped all external Nodes which are assocaited with a species not found in Tree reference.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SDI

public SDI(Tree gene_tree,
           Tree species_tree)
    throws java.lang.Exception
Constructor. Tree species_tree is a species Tree to which the gene Tree gene_tree will be compared to. Both Trees must be completely binary and rooted. The actual inference is accomplished with method infer().
Parameters:
gene_tree - reference to a rooted binary gene Tree to which assign duplication vs. speciation
species_tree - reference to a rooted binary species Tree which might be stripped in the process
Method Detail

infer

public abstract int infer(boolean strip_species_tree)
                   throws java.lang.Exception
Abstract method. Should infer for each Node of gene_tree whether it represents a speciation or duplication event. The most parsimonious sequence of speciation and duplication events should be assumed.
Parameters:
strip_species_tree - set to true to remove from the species tree species not found in the gene tree
Returns:
number of duplications which have been assigned in the gene Tree

stripTree

public static int stripTree(Tree reference,
                            Tree to_be_stripped)
Removes from Tree to_be_stripped all external Nodes which are assocaited with a species not found in Tree reference.
Parameters:
reference -  
to_be_stripped -  
Returns:
number of external nodes removed

main

public static void main(java.lang.String[] args)
A "main method" for SDI (Speciation versus Duplication Inference).
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