divlocus               package:hapsim               R Documentation

_D_i_v_e_r_s_i_t_y _s_c_o_r_e

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

     Compute a measure of genetic diversity at each locus

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

     divlocus(dat)

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

     dat: A binary matrix, rows are haplotypes and columns are binary
          markers 

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

     This function implements a measure of diversity for a locus j as
     in Clayton (2002). If z_ij represents the allele j of haplotype i,
     for i=1,...,N and assuming that alleles are coded as 0 and 1, the
     diversity measure can be written as

     D_j = 2*N( sum_{i=1}^N z_{ij}^2 - (sum_{i=1}^N z_{ij}) ^2 )

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

     A vector containing the diversity measure for all markers

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

     Giovanni Montana

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

     D. Clayton. Choosing a set of haplotype tagging SNPs from a larger
     set of diallelic loci. 2002. <URL:
     www-gene.cimr.cam.ac.uk/clayton/software/stata/htSNP/htsnp.pdf>

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

     data(ACEdata)
     divlocus(ACEdata)

