edu.rit.compbio.phyl
Class JukesCantorDistance

java.lang.Object
  extended by edu.rit.compbio.phyl.JukesCantorDistance
All Implemented Interfaces:
Distance

public class JukesCantorDistance
extends Object
implements Distance

Class JukesCantorDistance provides an object that computes the Jukes-Cantor distance between two DnaSequences. This is the corrected distance under the Jukes-Cantor model of DNA sequence evolution. The formula is

DJC = −3/4 N ln (1 − 4/3 DH/N)
where DJC is the Jukes-Cantor distance, DH is the Hamming distance (number of differing sites), and N is the number of sites. For further information, see:


Constructor Summary
JukesCantorDistance()
          Construct a new Jukes-Cantor distance object.
 
Method Summary
 double distance(DnaSequence seq1, DnaSequence seq2)
          Compute the distance between the two given DNA sequences.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JukesCantorDistance

public JukesCantorDistance()
Construct a new Jukes-Cantor distance object.

Method Detail

distance

public double distance(DnaSequence seq1,
                       DnaSequence seq2)
Compute the distance between the two given DNA sequences. It is assumed that the DNA sequences are the same length.

Specified by:
distance in interface Distance
Parameters:
seq1 - First DNA sequence.
seq2 - Second DNA sequence.
Returns:
Distance.


Copyright © 2005-2012 by Alan Kaminsky. All rights reserved. Send comments to ark­@­cs.rit.edu.