[Bioperl-l] problems with the Bio::Tools::Run::Genewise module
Jack Chen
chenn at cshl.edu
Thu Oct 14 22:33:24 EDT 2004
Hi, Keith, Jason et al.,
I need you help with this module. I am trying to run genewise and parse
genewise result using the module. The simple script I wrote did not work
as expected. While I could get the exon coordinates correctly, I could not
retrieve sequence data properly. When I ran the program on command line, I
could get correct sequences.
Thanks,
Jack
============
#!/usr/bin/perl -w
use strict;
use Getopt::Long;
use Bio::SeqIO;
use Bio::Tools::Run::Genewise;
use Data::Dumper;
my ($hmmfile, $gen);
GetOptions('hmm|h:s' => \$hmmfile,
'genomic|g:s'=> \$gen);
my $genomic_seq = Bio::SeqIO->new(-file => $gen, -format => 'FASTA');
my $factory = Bio::Tools::Run::Genewise->new('both' => 1, 'silent' => 1);
$factory->hmmer(1);
my @genes = $factory->run($hmmfile, $genomic_seq->next_seq);
for my $g (@genes){
my @transcripts = $g->transcripts();
for my $tran (@transcripts){
print $tran->cds, "\n";
}
}
More information about the Bioperl-l
mailing list