edu.cornell.med.alignments
Class AlignmentConservation

java.lang.Object
  extended by edu.cornell.med.alignments.AlignmentConservation

public class AlignmentConservation
extends Object

Takes in an alignment in ClustalW format, parses it into a BiologicalAlignment, and calculates at each position whether the alignment reaches a user-specified conservation cutoff value.

Author:
luce

Constructor Summary
AlignmentConservation()
          Constructor.
 
Method Summary
 String calculateConservation(double cutoff, boolean gaps, char mark)
          Calculates the conservation at each position in the alignment.
 edu.mssm.crover.representation.BiologicalAlignment getAln()
          Gets the alignment.
 int length()
          Gets the length of the alignment.
static void main(String[] args)
          Main method.
 int numSeqs()
          Gets the number of sequences in the alignment.
 void setAln(edu.mssm.crover.representation.BiologicalAlignment alignment)
          Sets the alignment.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AlignmentConservation

public AlignmentConservation()
Constructor. Assigns a new (empty) alignment.

Method Detail

getAln

public final edu.mssm.crover.representation.BiologicalAlignment getAln()
Gets the alignment.

Returns:
the alignment

setAln

public final void setAln(edu.mssm.crover.representation.BiologicalAlignment alignment)
Sets the alignment.

Parameters:
alignment - the alignment

numSeqs

public final int numSeqs()
Gets the number of sequences in the alignment.

Returns:
the number of sequences

length

public final int length()
Gets the length of the alignment.

Returns:
the length of the alignment.

calculateConservation

public final String calculateConservation(double cutoff,
                                          boolean gaps,
                                          char mark)
Calculates the conservation at each position in the alignment.

Parameters:
cutoff - The percentage cutoff for which a position is considered conserved
gaps - Whether gaps are counted when looking at a position
mark - The type of mark used to indicate that a position is conserved
Returns:
The conservation line, where each posotion in the alignment is marked as being conserved at that position

main

public static void main(String[] args)
Main method.

Parameters:
args - The command line arguments.


Copyright © 2007 Institute for Computational Biomedicine, All Rights Reserved.