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"))

_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:

          ## 2005-10-13: NCBI URLs responding with encoding issue,
          ## commenting out example:
          ## ## 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")

