[Bioperl-l] Problem retrieving CDS by Acession #

Sean Davis sdavis2 at mail.nih.gov
Thu Sep 7 10:48:05 UTC 2006


On Thursday 07 September 2006 01:09, Ryan Golhar wrote:
> Hi,
>
> I'm using Bio::DB::GenBank::get_Seq_by_acc() passing in a valid
> accession #, XM_547879.2, for instance.
>
> I get the message in return:
>
> -------------------- WARNING ---------------------
> MSG: acc (gb|XM_547879.2) does not exist
> ---------------------------------------------------
>
> If I go to NCBI, and enter the accession, the GenBank entry comes up.
> At first I suspected it was the version number, but removing the version
> number still causes the same error.
>
> Am I doing something wrong?

from the Docs for Bio::DB::Genbank:

    $seq = $gb->get_Seq_by_acc('J00522'); # Accession Number
    $seq = $gb->get_Seq_by_version('J00522.1'); # Accession.version
    $seq = $gb->get_Seq_by_gi('405830'); # GI Number

So, you might try using get_Seq_by_version(....).  I didn't test it, but give 
that a shot.

Sean



More information about the Bioperl-l mailing list