

commandArgs {base}                           R Documentation

_E_x_t_r_a_c_t _C_o_m_m_a_n_d _L_i_n_e _A_r_g_u_m_e_n_t_s

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

     Provides access to a copy of the command line arguments
     supplied when this R session was invoked.

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

     commandArgs()

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

     These arguments are captured before the standard R com-
     mand line processing takes place. This means that they
     are the unmodified values.  If it were useful, we could
     provide support an argument which indicated whether we
     want the unprocessed or processed values.

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

     A character vector containing the name of the exe-
     cutable and the user-supplied command line arguments.
     The first element is the name of the executable by
     which R was invoked. As far as I am aware, the exact
     form of this element is platform dependent. It may be
     the fully qualified name, or simply the last component
     (or basename) of the application.

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

     `BATCH'

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

       commandArgs()
     # Spawn a copy of this  application as it was invoked.
     # system(paste(commandArgs(),collapse=" "))

