accessionToUID           package:annotate           R Documentation

_A _f_u_n_c_t_i_o_n _t_o _c_o_n_v_e_r_t _a_c_c_e_s_s_i_o_n _v_a_l_u_e_s _t_o _N_C_B_I _U_I_D_s.

_D_e_s_c_r_i_p_t_i_o_n:

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

_U_s_a_g_e:

     accessionToUID(...,db=c("genbank","pubmed")[1])

_A_r_g_u_m_e_n_t_s:

     ...: Accession numbers to be transformed.

      db: Which database this accession number refers to, defaults to
          Genbank

_D_e_t_a_i_l_s:

     Utilizes the PubMed tool pmqty.cgi 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.

_V_a_l_u_e:

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

_A_u_t_h_o_r(_s):

     Jeff Gentry

_S_e_e _A_l_s_o:

     'pubmed', 'locuslinkByID', 'locuslinkQuery', 'xmlTreeParse'

_E_x_a_m_p_l_e_s:

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

          ## Can handle multiple inputs
          accessionToUID("M16653","U892893",db="pubmed")

