[Bioperl-l] An example to query PMID given GEO accession number?

Smithies, Russell Russell.Smithies at agresearch.co.nz
Wed Jun 17 01:21:18 UTC 2015


Not sure as it's not something I've done.
Submit them one at a time maybe?

--Russell

-----Original Message-----
From: Peng Yu [mailto:pengyu.ut at gmail.com] 
Sent: Wednesday, 17 June 2015 1:18 p.m.
To: Smithies, Russell
Cc: Fields, Christopher J; bioperl-l at lists.open-bio.org
Subject: Re: [Bioperl-l] An example to query PMID given GEO accession number?

> Have you been reading the documentation? Then elink example provided on the bioperl wiki should do most of what you want.
> http://www.bioperl.org/wiki/HOWTO:EUtilities_Cookbook#elink
>
> Also docs at NCBI so you can create your own URLs then 'manually' pull 
> in results then parse the XML 
> http://www.ncbi.nlm.nih.gov/books/NBK25500/
>
> ------------------------------------------
> use Bio::DB::EUtilities;
>
> my @ids     = qw(200039684 200039685);

When there are GDS IDs (e.g., 200069227) without Pubmed IDs, the lengths of $ds->get_submitted_ids and $ds->get_ids will be different.
In this the pair information will be lost. How to keep the pair information? (I am not sure if this is addressed in the cookbook.)

> my $factory = Bio::DB::EUtilities->new(-eutil  => 'elink',
>                                        -email  => 'mymail at foo.bar',
>                                        -db     => 'pubmed',
>                                        -dbfrom => 'gds',
>                                        -id     => \@ids);
>
> # iterate through the LinkSet objects
> while (my $ds = $factory->next_LinkSet) {
>     print " Link name: ",$ds->get_link_name,"\n";
>     print "Pubmed IDs: ",join(',',$ds->get_submitted_ids),"\n";

The above should be GDS IDs.

>     print "   GDS IDs: ",join(',',$ds->get_ids),"\n";

The above should be Pubmed IDs.

> }

--
Regards,
Peng



More information about the Bioperl-l mailing list