deparse                 package:base                 R Documentation

_E_x_p_r_e_s_s_i_o_n _D_e_p_a_r_s_i_n_g

_D_e_s_c_r_i_p_t_i_o_n:

     Turn unevaluated expressions into character strings.

_U_s_a_g_e:

     deparse(expr, width.cutoff = 60)

_A_r_g_u_m_e_n_t_s:

    expr: any R expression.

width.cutoff: integer in [20, 500] determining the cutoff at which
          line-breaking is tried.

_D_e_t_a_i_l_s:

     This function turns unevaluated expressions (where ``expression''
     is taken in a wider sense than the strict concept of a vector of
     mode `"expression"' used in `expression') into character strings
     (a kind of inverse `parse').

     A typical use of this is to create informative labels for data
     sets and plots.  The example shows a simple use of this facility. 
     It uses the functions `deparse' and `substitute' to create labels
     for a plot which are character string versions of the actual
     arguments to the function `myplot'.

_S_e_e _A_l_s_o:

     `substitute', `parse', `expression'.

_E_x_a_m_p_l_e_s:

     deparse(args(lm))
     deparse(args(lm), width = 100)
     myplot <-
     function(x, y)
         plot(x, y, xlab=deparse(substitute(x)),
             ylab=deparse(substitute(y)))

