call                  package:base                  R Documentation

_F_u_n_c_t_i_o_n _C_a_l_l_s

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

     Create or test for objects of mode '"call"'.

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

     call(name, ...)
     is.call(x)
     as.call(x)

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

    name: a character string naming the function to be called.

     ...: arguments to be part of the call.

       x: an arbitrary R object.

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

     'call' returns an unevaluated function call, that is, an
     unevaluated expression which consists of the named function
     applied to the given arguments ('name' must be a quoted string
     which gives the name of a function to be called).

     'is.call' is used to determine whether 'x' is a call (i.e., of
     mode '"call"'). It is generic: you can write methods to handle
     specific classes of objects, see InternalMethods.

     Objects of mode '"list"' can be coerced to mode '"call"'. The
     first element of the list becomes the function part of the call,
     so should be a function or the name of one (as a symbol; a quoted
     string will not do).

_R_e_f_e_r_e_n_c_e_s:

     Becker, R. A., Chambers, J. M. and Wilks, A. R. (1988) _The New S
     Language_. Wadsworth & Brooks/Cole.

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

     'do.call' for calling a function by name and argument list;
     'Recall' for recursive calling of functions; further
     'is.language', 'expression', 'function'.

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

     is.call(call) #-> FALSE: Functions are NOT calls

     # set up a function call to round with argument 10.5
     cl <- call("round", 10.5)
     is.call(cl)# TRUE
     cl
     # such a call can also be evaluated.
     eval(cl)# [1] 10

