Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

accessionToUID

A function to convert accession values to NCBI UIDs.


Description

Given one or more accession values, this function will attempt to convert them into NCBI UID values.

Usage

accessionToUID(...,db=c("genbank","pubmed"))

Arguments

...

Accession numbers to be transformed.

db

Which database this accession number refers to, defaults to Genbank

Details

Utilizes the PubMed tool esearch.fcgi to convert an accession number into a valid NCBI UID number.

WARNING: The powers that be at NCBI have been known to ban the IP addresses of users who abuse their servers (currently defined as less then 2 seconds between queries). Do NOT put this function in a type loop or you may find your access revoked.

Value

Returns either a valid NCBI UID value or NULL (if there was nothing available).

Author(s)

Jeff Gentry

See Also

Examples

## The two returns from genbank should be the same
     xdoc <- genbank("U03397",type="accession",disp="data")
     x <- accessionToUID("U03397",db="genbank")
     xdoc <- genbank(x, type="uid",disp="data")

     ## Can handle multiple inputs
     y <- accessionToUID("M16653","U892893",db="genbank")

annotate

Annotation for microarrays

v1.68.0
Artistic-2.0
Authors
R. Gentleman
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.