BString-class package:Biostrings R Documentation _T_h_e _B_S_t_r_i_n_g _c_l_a_s_s _D_e_s_c_r_i_p_t_i_o_n: The 'BString' class is a general container for storing a big string (a long sequence of characters) and to make its manipulation easy and efficient. The 'DNAString', 'RNAString' and 'AAString' classes are direct 'BString' derivations with the more specific purpose of storing a DNA sequence ('DNAString'), a RNA sequence ('RNAString') or a sequence of amino acids ('AAString'). _D_e_t_a_i_l_s: The 2 main differences between a 'BString' object and a standard character vector are: (1) the data stored in a 'BString' object are not copied on object duplication and (2) a 'BString' can only store a single string (see the 'BStringViews' for an efficient way to store a collection of big strings in a single object). A 'BString' object can be used to store any non-empty string based on a single-byte character set. _A_c_c_e_s_o_r _m_e_t_h_o_d_s: In the code snippets below, 'x' is a 'BString' (or derived) object and 'i' is a numeric vector. 'letter(x, i)': [TODO: Document me] _C_o_n_s_t_r_u_c_t_o_r-_l_i_k_e _f_u_n_c_t_i_o_n_s _a_n_d _g_e_n_e_r_i_c_s: In the code snippet below, 'src' can be a character vector or a 'BString' (or derived) object. 'BString(src)': [TODO: Document me] _S_t_a_n_d_a_r_d _g_e_n_e_r_i_c _m_e_t_h_o_d_s: In the code snippets below, 'x', 'object', 'e1' and 'e2' are 'BString' (or derived) objects, and 'i' is a numeric vector. 'length(x)' or 'nchar(x)': Used to get the length of a 'BString', i.e., its number of letters 'x[i]': [TODO: Document me] 'e1 == e2': [TODO: Document me] 'e1 != e2': [TODO: Document me] 'as.character(x)': [TODO: Document me] 'toString(x)': [TODO: Document me] _O_t_h_e_r _f_u_n_c_t_i_o_n_s _a_n_d _g_e_n_e_r_i_c_s: In the code snippets below, 'x' is a 'BString' (or derived) object and 'first' and 'last' are single numerics. 'subBString(x, first, last)': [TODO: Document me] _A_u_t_h_o_r(_s): H. Pages _S_e_e _A_l_s_o: DNAString-class, RNAString-class, AAString-class BStringViews-class _E_x_a_m_p_l_e_s: b <- BString("I am a BString object") length(b)