getPackageName            package:methods            R Documentation

_T_h_e _n_a_m_e _a_s_s_o_c_i_a_t_e_d _w_i_t_h _a _g_i_v_e_n _p_a_c_k_a_g_e

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

     The functions below produce the package associated with a
     particular environment or position on the search list, or of the
     package containing a particular function.  They are primarily used
     to support computations that need to differentiate objects on
     multiple packages.

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

     getPackageName(where = 1)
     functionPackageName(name)

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

   where: The environment or position on the search list associated
          with the desired package. 

    name: The name of a function:  `functionPackageName' finds the
          function and returns the package name corresponding. Note
          that if there are multiple instances of the function, all the
          corresponding names are returned. 

     pkg: The name to be assigned to the package internally. 

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

     Package names are normally installed during loading of the
     package, by the INSTALL script or by the `library' function. 
     (Currently, the name is stored as the object `.packageName' but
     don't trust this for the future.)

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

     All the functions return the character-string name of the package
     (without the extraneous `"package:"' found in the search list).

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

     `search'

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

     ## both the following usually return "base"
     getPackageName(length(search()))

     functionPackageName("rnorm")

