[Bioperl-l] alignment

Guoneng Zhong Guoneng.Zhong@med.nyu.edu
Tue, 19 Feb 2002 10:45:21 -0500


Hi,
Has anyone done a simple pairwise alignment on DNA strands?  The 
examples in the docs and tutorial are about protein alignment using the 
Smith-Waterman algorithm.  I tried to assign a dna matrix to the 
"-matrix" parameter and it kept telling me that my sequences are not 
proteins.  Here is the code snippet:

$seq1 = Bio::Seq->new
(-id=>"seq1",-seq=>"AATTATATAATATATCTCTCCTCTTGCTCTC");
$seq2 = Bio::Seq->new
(-id=>"seq2",-seq=>"AATTATATAATATATGCCTCCCCCTTACTCTC");
#$factory = new Bio::Tools::pSW('-matrix'=>'NUC4X4HB.MNT');
$factory = new Bio::Tools::pSW('-matrix'=>'nu.bla');
$aln = $factory->pairwise_alignment($seq1,$seq2);
foreach $seq ($aln->eachSeq()){
     print "$seq\n";
}

Any idea why?  Or does this module work only for proteins?

Thanks,
G