prmatrix                package:base                R Documentation

_P_r_i_n_t _M_a_t_r_i_c_e_s, _O_l_d-_s_t_y_l_e

_D_e_s_c_r_i_p_t_i_o_n:

     An earlier method for printing matrices, provided for S
     compatibility.

_U_s_a_g_e:

     prmatrix(x, rowlab =, collab =,
              quote = TRUE, right = FALSE, na.print = NULL, ...)

_A_r_g_u_m_e_n_t_s:

       x: numeric or character matrix.

rowlab,collab: (optional) character vectors giving row or column names
          respectively.  By default, these are taken from
          'dimnames(x)'.

   quote: logical; if 'TRUE' and 'x' is of mode '"character"', _quotes_
          ('"') are used.

   right: if 'TRUE' and 'x' is of mode '"character"', the output
          columns are _right_-justified.

na.print: how 'NA's are printed.  If this is non-null, its value is
          used to represent 'NA'.

     ...: arguments for 'print' methods.

_D_e_t_a_i_l_s:

     'prmatrix' is an earlier form of 'print.matrix', and is very
     similar to the S function of the same name.

_V_a_l_u_e:

     Invisibly returns its argument, 'x'.

_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:

     'print.default', and other 'print' methods.

_E_x_a_m_p_l_e_s:

     prmatrix(m6 <- diag(6), rowlab = rep("",6), collab =rep("",6))

     chm <- matrix(scan(system.file("help", "AnIndex", package = "splines"),
                        what = ""), , 2, byrow = TRUE)
     chm  # uses print.matrix()
     prmatrix(chm, collab = paste("Column",1:3), right=TRUE, quote=FALSE)

