size                 package:arules                 R Documentation

_G_e_t_t_i_n_g _t_h_e _S_i_z_e _o_f _E_a_c_h _E_l_e_m_e_n_t

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

     Provides the generic function 'size' and S4 methods to get the
     size of each element from objects based on 'itemMatrix'.  For
     example, it is used to get a vector of transaction sizes (i.e.,
     the number of present items (ones) per element (row) of the binary
     incidence matrix) from an object of class 'transactions').

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

     size(x, ...)

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

       x: an object.

     ...: further (unused) arguments.

_V_a_l_u_e:

     'size' returns a numeric vector of length 'length(x)'.  Each
     element is the size of the corresponding element (row in the
     matrix) in object 'x'. For rules, 'size' returns the sum of the
     number of elements in the LHS and the RHS.

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

     'itemMatrix-class', 'transactions-class'

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

     data("Adult")
     summary(size(Adult))

