abIndex-class             package:Matrix             R Documentation

_C_l_a_s_s "_a_b_I_n_d_e_x" _o_f _A_b_s_t_r_a_c_t _I_n_d_e_x _V_e_c_t_o_r_s

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

     The '"abIndex"' 'class', short for Abstract Index Vector, is
     used for dealing with large index vectors more efficiently, than
     using integer (or 'numeric') vectors of the kind '2:1000000' or
     'c(0:1e5, 1000:1e6)'.

_O_b_j_e_c_t_s _f_r_o_m _t_h_e _C_l_a_s_s:

     Objects can be created by calls of the form 'new("abIndex", ...)',
     or more easily by 'as(x, "abIndex")' where 'x' is an integer
     (valued) vector.

_S_l_o_t_s:


     '_k_i_n_d': Object of class '"character"' ~~ 

     '_x': Object of class '"numIndex"' ~~ 

     '_r_l_e_D': Object of class '"rleDiff"' ~~ 

_M_e_t_h_o_d_s:


     _a_s._n_u_m_e_r_i_c 'signature(x = "abIndex")': ... 

     [ 'signature(x = "abIndex", i = "index", j = "ANY", drop =
          "ANY")': ... 

     _c_o_e_r_c_e 'signature(from = "numeric", to = "abIndex")': ... 

     _c_o_e_r_c_e 'signature(from = "abIndex", to = "numeric")': ... 

     _c_o_e_r_c_e 'signature(from = "abIndex", to = "integer")': ... 

     _l_e_n_g_t_h 'signature(x = "abIndex")': ... 

     _O_p_s 'signature(e1 = "numeric", e2 = "abIndex")': These and the
          following arithmetic and logic operations are *not yet
          implemented*; see 'Ops' for a list of these (S4) group
          methods.

     _O_p_s 'signature(e1 = "abIndex", e2 = "abIndex")': ... 

     _O_p_s 'signature(e1 = "abIndex", e2 = "numeric")': ... 

     _S_u_m_m_a_r_y 'signature(x = "abIndex")': ... 

_N_o_t_e:

     This is currently experimental and not yet used for our own code.
     Please contact us ('packageDescription("Matrix")$Maintainer'), if
     you plan to make use of this class.

     Partly builds on ideas and code from Jens Oehlschlaegel, as
     implemented (around 2008, in the GPL'ed part of) package 'ff'.

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

     'rle' ('base') which is used here. 'numeric'

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

     showClass("abIndex")
     ii <- c(-3:40, 20:70)
     str(ai <- as(ii, "abIndex"))# note

