comp.trees             package:Rtreemix             R Documentation

_F_u_n_c_t_i_o_n_s _f_o_r _q_u_a_n_t_i_f_y_i_n_g _t_h_e _d_i_v_e_r_s_i_t_y _o_f _t_h_e _n_o_n_t_r_i_v_i_a_l _t_r_e_e_s _i_n
_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:

     These functions implement a similarity measure for comparing the
     topologies of the nontrivial tree components of a specified
     mixture model, and thereby quantifying their diversity. All
     possible pairs of nontrivial components are considered when
     computing the similarity. 'comp.trees' uses the sum of the number
     of different edges of all pairs for caracterizing the difference
     of the trees in the model. 'comp.trees.levels' uses the sum of the
     number of different edges of all pairs and the corresponding L1
     distances of their level vectors. The model must have at least two
     nontrivial components.

_U_s_a_g_e:

     comp.trees(model)
     comp.trees.levels(model)

_A_r_g_u_m_e_n_t_s:

   model: An 'RtreemixModel' object.

_V_a_l_u_e:

     The functions return a numeric value that quantifies the
     similarity (or diversity) of the nontrivial tree topologies of a
     given mixture models.

_A_u_t_h_o_r(_s):

     Jasmina Bogojeska

_S_e_e _A_l_s_o:

     'RtreemixModel-class', 'comp.models', 'fit-methods',
     'stability.sim'

_E_x_a_m_p_l_e_s:

     ## Generate two random RtreemixModel objects each with 3 components.
     mix1 <- generate(K = 3, no.events = 9, noise.tree = TRUE, prob = c(0.2, 0.8))
     mix2 <- generate(K = 3, no.events = 9, noise.tree = TRUE, prob = c(0.2, 0.8))
     ## Inspect the diversity of the nontrivial tree components in a given model
     ## using the number of distinct edges and the levels of the events in
     ## the treesas dissimilarity measure.
     comp.trees.levels(model = mix1)
     comp.trees.levels(model = mix2)

