I am a confused by the different interpretation of get_seq_by_id. Obviously
it is something different for the two modules.
Script1:
#!/bin/perl -w
use Bio::DB::GenBank;
use Bio::SeqIO;
# Das output-Format wird festgelegt
$seqio_obj = Bio::SeqIO->new(-file => '>sequence.fasta', -format => 'fasta'
);
$db_obj = Bio::DB::GenBank->new;
$id = "BC049766"; # accesscion number
$seq_obj = $db_obj->get_Seq_by_id($id);
$seqio_obj->write_seq($seq_obj);
Script2:
#!/bin/perl -w
use strict;
use Bio::DB::EntrezGene;
my $id = "Penk1"; #name of the gene
my $db = new Bio::DB::EntrezGene;
my $seq = $db->get_Seq_by_id($id);
my $ac = $seq->annotation;
for my $ann ($ac->get_Annotations('dblink')) {
if ($ann->database eq "Evidence Viewer") {
# get the sequence identifier, the start, and the stop
my ($contig,$from,$to) = $ann->url =~
/contig=([^&]+).+from=(\d+)&to=(\d+)/;
print "$contig\t$from\t$to\n";
}
}
Thank you
Hermann Norpois
_______________________________________________
Bioperl-l mailing list
Bioperl-l@...
http://lists.open-bio.org/mailman/listinfo/bioperl-l