bnrf1                  package:VLMC                  R Documentation

_B_N_R_F_1 _G_e_n_e _D_N_A _s_e_q_u_e_n_c_e_s: _E_p_s_t_e_i_n-_B_a_r_r _a_n_d _H_e_r_p_e_s

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

     Two gene DNA data ``discrete time series'',

     '_b_n_r_f_1_E_B' the BNRF1 gene from the Epstein-Barr virus,

     '_b_n_r_f_1_H_V' the BNRF1 gene from the herpes virus.

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

     data(bnrf1)

_F_o_r_m_a_t:

     The EB sequence is of 'length' 3954, whereas the HV has 3741
     nucleotides. Both are R 'factor's with the four levels
     'c("a","c","g","t")'.

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

     Martin Maechler (packaging for R).

_S_o_u_r_c_e:

     See the references, data are online at <URL:
     http://anson.ucdavis.edu/~shumway/tsa.html>

_R_e_f_e_r_e_n_c_e_s:

     Shumway, R. and Stoffer, D. (2000) _Time Series Analysis and its
     Applications_. Springer Texts in Statistics.

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

     data(bnrf1)
     bnrf1EB[1:500]
     table(bnrf1EB)
     table(bnrf1HV)
     n <- length(bnrf1HV)
     table(t = bnrf1HV[-1], "t-1" = bnrf1HV[-n])

     require(ts)
     plot(as.integer(bnrf1EB[1:500]), type = "b")


     ## Simplistic gene matching:
     percent.eq <- sapply(0:200,
                function(i) 100 * sum(bnrf1EB[(1+i):(n+i)] ==  bnrf1HV))/n
     plot.ts(percent.eq)

