如果有人能帮助我获取以下代码来输出输入文件(http://biopython.org/DIST/docs/tutorial/examples/ls_orchid.gbk)中所有记录的序列(包括ID),我会很高兴:
use Bio::SeqIO;
use Bio::Seq;
use Bio::DB::GenBank;
$seq_obj = Bio::SeqIO->new(-file => "ls_orchid.gbk" , '-format' => 'genbank');
$seqio_obj2 = Bio::SeqIO->new(-file => '>sequence.fasta', -format => 'genbank' );
while ( my $seq = $seq_obj->next_seq() ) {
print "Sequence ",$seq->id ($seq_obj)"\n";
#print $seq_obj->seq,"\n";
$seqio_obj2->write_seq($seq_obj);
}
我希望看到由纯序列(最好带有标题)组成的输出如下:
seq1:
ATTCGCTGCATGACAT..........
Seq2:
ACTGCGATGGATGGAT..
谢谢