

getenv {base}                                R Documentation

_G_e_t _E_n_v_i_r_o_n_m_e_n_t _V_a_r_i_a_b_l_e_s

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

     `getenv' obtains the values of the environment vari-
     ables named by `x'.

_U_s_a_g_e_:

     getenv(x)

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

       x: a character vector, or missing

_V_a_l_u_e_:

     A vector of the same length as `x', with the variable
     names as its `names' attribute.  Each element holds the
     value of the environment variable named by the corre-
     sponding component of `x' (or `""' if no environment
     variable with that name was found).

     On some platforms `getenv()' will return a named vector
     giving the values of all the environment variables.

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

     `getwd' for the working directory.

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

     getenv(c("R_HOME", "R_PAPERSIZE", "R_PRINTCMD", "HOST"))

