asSimpleVector            package:RBioinf            R Documentation

_E_x_a_m_p_l_e _f_u_n_c_t_i_o_n_s _f_o_r _t_h_e _C_h_a_p_t_e_r _o_n _D_e_b_u_g_g_i_n_g

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

     These functions are used to demonstrate some of the debugging
     facilities in R.

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

     asSimpleVector(x, mode = "logical")
     convertMode(from, to)
     setVNames(x, nm)
     subsetAsCharacter(x, i, j)

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

       x: input 

    mode: the mode of 'x' 

    from: a parameter

      to: another parameter

      nm: names for 'x'

       i: an index

       j: another index

_D_e_t_a_i_l_s:

     A set of functions that can be used to demonstrate debugging
     principles  and practices.

     'asSimpleVector'  converts the argument 'x' to a simple R vector
     of the given mode preserving names, dimension and dimnames.

     'subsetAsCharacter' calculates either a vector or a matrix subset
     of the argument 'x' and returns the subset after converting it to
     be of mode character. It uses 'asSimpleVector' to do the
     conversion to character and thus also preserves any names,
     dimension or dimnames in the subset.

     'setVNames' sets the names of the given vector 'x' to the argument
     'nm' and then converts 'x' to numeric using 'asSimpleVector'.

     'convertMode' converts its first argument to the mode of the
     second argument.

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

     Various values are returned.

_A_u_t_h_o_r(_s):

     S. DebRoy

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

     'browser'

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

