标签:str use new 转换 warnings inf fast ast ext
#!/usr/bin/env perl
use strict;
use warnings;
sub TranslateDNAFile(){
use Bio::SeqIO;
(my $infile,my $outfile)=@_;
my $in=Bio::SeqIO->new(-file=>"$infile",-format=>"fasta");
my $out=Bio::SeqIO->new(-file=>">$outfile", -format=>"fasta");
while (my $seq=$in->next_seq()){
$out->write_seq($seq->translate);
}
}
my $DNAfile="in_cds";
my $pepfile="out_pep";
&TranslateDNAFile($DNAfile,$pepfile);
标签:str use new 转换 warnings inf fast ast ext
原文地址:https://www.cnblogs.com/erinaceinae/p/9462035.html