all                   package:base                   R Documentation

_A_r_e _A_l_l _V_a_l_u_e_s _T_r_u_e?

_D_e_s_c_r_i_p_t_i_o_n:

     Given a set of logical vectors, are all of the values true?

_U_s_a_g_e:

     all(..., na.rm = FALSE)

_A_r_g_u_m_e_n_t_s:

     ...: one or more logical vectors.

   na.rm: logical. If true `NA' values are removed before the result is
          computed.

_V_a_l_u_e:

     Given a sequence of logical arguments, a logical value indicating
     whether or not all of the elements of `x' are `TRUE'.

     The value returned is `TRUE' if all the values in `x' are `TRUE',
     and `FALSE' if any the values in `x' are `FALSE'.

     If `x' consists of a mix of `TRUE' and `NA' values, then value is
     `NA'.

_S_e_e _A_l_s_o:

     `any', the ``complement'' of `all', and `stopifnot(*)' which is an
     `all(*)' ``insurance''.

_E_x_a_m_p_l_e_s:

     range(x <- sort(round(rnorm(10) - 1.2,1)))
     if(all(x < 0)) cat("all x values are negative\n")

