[Bioperl-l] Arrays of BioSeq and TCoffee
James Wasmuth
james.wasmuth@ed.ac.uk
Thu Jan 16 19:54:24 EST 2003
Hi people,
I have a number of fasta format sequences in one string, which I wish to
align using T-Coffee, without writing the sequences to a file first.
According to doc for T-Coffee module, the align method will take a
filename or an array of references for Bio::Seq objects...
I've tried the following script but it fails, I am informed that the
first Bio::Seq object contains less than 2 sequences. Well of course it
does, its a Bio::Seq object... Can anyone see my error...
my @fasta_seq = qw/ >seq1\nFTTATT >seq2\nFTTGTT >seq3\nFTATTT /;
my @seq;
foreach (@fasta_seq) {
my $stringfh = new IO::String($_);
my $seqio = new Bio::SeqIO(-fh => $stringfh, -format => 'fasta');
push @seq ($seqio_obj->next_seq);
}
# here I know that @seq is an array of Bio::Seq objects
my @params = (some params);
my $factory = new Bio::Tools::Run::Alignment::TCoffee (@params);
my $aln = $factory->align(@seq);
Can a Bio::Seq object hold more than one sequence? Is that my problem
Many Thanks
J
More information about the Bioperl-l
mailing list