likelihoods-methods         package:Rtreemix         R Documentation

_M_e_t_h_o_d _f_o_r _p_r_e_d_i_c_t_i_n_g _t_h_e _l_i_k_e_l_i_h_o_o_d_s _o_f _a _s_e_t _o_f _s_a_m_p_l_e_s _w_i_t_h
_r_e_s_p_e_c_t _t_o _a _m_u_t_a_g_e_n_e_t_i_c _t_r_e_e_s _m_i_x_t_u_r_e _m_o_d_e_l

_D_e_s_c_r_i_p_t_i_o_n:

     This function predicts the (log, weighted) likelihoods of the
     samples in a given dataset according to a given mutagenetic trees
     mixture model. The dataset and the model have to be specified.

_U_s_a_g_e:

     ## S4 method for signature 'RtreemixModel, RtreemixData':
     likelihoods(model, data)

_A_r_g_u_m_e_n_t_s:

   model: An 'RtreemixModel' object specifying the probabilistic
          framework in which the likelihoods of the genetic patterns
          are computed.

    data: An 'RtreemixData' object giving the samples for which the
          likelihoods are to be calculated.

_V_a_l_u_e:

     This method returns an 'RtreemixStats' object that containes the
     weghted- and log-likelihoods of the samples in the given dataset
     with respect to the given mutagenetic trees mixture model.

_A_u_t_h_o_r(_s):

     Jasmina Bogojeska

_R_e_f_e_r_e_n_c_e_s:

     Learning multiple evolutionary pathways from cross-sectional data,
     N. Beerenwinkel et al.

_S_e_e _A_l_s_o:

     'RtreemixData-class', 'RtreemixModel-class', 'fit-methods',
     'distribution-methods'

_E_x_a_m_p_l_e_s:

     ## Create an RtreemixData object from a randomly generated RtreemixModel object.
     rand.mod <- generate(K = 3, no.events = 9, noise.tree = TRUE, prob = c(0.2, 0.8))
     data <- sim(model = rand.mod, no.draws = 300)
     show(data)

     ## Compute the likelihoods of the samples in data with respect to the model rand.mod
     mod.stat <- likelihoods(model = rand.mod, data = data)
     show(mod.stat)

