Report private alleles (and fixed alleles) per pair of populations
This function reports private alleles in one population compared with a second population, for all populations taken pairwise. It also reports a count of fixed allelic differences and the mean absolute allele frequency differences between pairs of populations.
gl.report.pa(gl1, gl2 = NULL, verbose = NULL)
gl1 |
– name of the genlight object containing the SNP data [required] |
gl2 |
– if two seperate genlight objects are to be compared this can be provided here [default NULL] |
verbose |
– verbosity: 0, silent, fatal errors only; 1, flag function begin and end; 2, progress log ; 3, progress and results summary; 5, full report [default 2 or as specified using gl.set.verbosity] |
Note that the number of paired alleles between to populations is not a symmetric dissimilarity measure.
if no gl2 is provided, the function uses the pop(gl) hierachy to determine pairs of population, otherwise it runs a single comparison between gl1 and gl2. Hint: in case you want to run comparison between individuals you can simply redefine your pop(gl) via indNames(gl) [Assuming individual names are unique]
Definition of fixed and private alleles
The table shows a cross table of possible cases of allele frequencies between two populations (0=homozygote for Allele 1,x= both Alleles are present, 1=homozygote for Allele 2)
p: cases where there is a private allele in pop1 compared to pop2 (but not vice versa)
f: cases where there is a fixed allele in pop1 (and pop2, as those cases are symmetric)
pop1 | ||||
0 | x | 1 | ||
0 | - | p | p,f | |
pop2 | x | - | - | - |
1 | p,f | p | - | |
returns a data.frame. Each row shows for a pair of populations the number of individuals in a population, the number of loci with fixed differences (same for both populations) in pop1 (compared to pop2) and vice versa. Same for private alleles and finally the absolute mean allele frequendy difference between loci (mdf).
Bernd Gruber (Post to https://groups.google.com/d/forum/dartr)
out <- gl.report.pa(testset.gl[1:20,])
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.