

_M_a_t_r_i_c_e_s

     matrix(data = NA, nrow = 1, ncol = 1, byrow = FALSE, dimnames = NULL)
     as.matrix(x)
     is.matrix(x)

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

     `matrix' creates a matrix from the given set of values.
     `nrow' gives the desired number of rows and `ncol' the
     desired number of columns.  If either of `nrow' or
     `ncol' is not given, an attempt is made to infer it
     from the length of `data' and the other parameter.  If
     `byrow' is `FALSE' (the default) the matrix is filled
     by columns, otherwise the matrix is filled by rows.  A
     `dimnames' attribute for the matrix can be specified
     with the optional `dimnames' argument (which thus has
     to be a `list' of length 2).

     `as.matrix' attempts to turn its argument into a
     matrix.  This function is generic with a default and a
     `data.frame' method.

     `is.matrix' returns `TRUE' if `x' is a matrix (i.e., it
     not a `data.frame' and has a `dim' attribute of length
     2) and `FALSE' otherwise.

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

     `data.matrix'.

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

     is.matrix(as.matrix(1:10))
     data(warpbreaks)
     !is.matrix(warpbreaks)# data.frame, NOT matrix!
     str(warpbreaks)
     str(as.matrix(warpbreaks))#using as.matrix.data.frame(.) method

