Description Usage Arguments Value Source Examples
View source: R/population-stats.R
This function calculates the expected heterozygosity of each of the markers
in the given freqt
object according to the formula
H_e = 1 - ∑_{i = 0}^n p_i^2,
where n is the number of alleles for the marker in question and p_i is the probability of allele i.
1 | expected_heterozygosity(x, ms = NULL)
|
x |
a |
ms |
a list of markers for which the expected heterozygosities will be
calculated. By default they are calculated for every marker in the given
|
a numeric vector containing the expected heterozygosities
https://www.uwyo.edu/dbmcd/molmark/lect04/lect4.html
1 2 3 4 5 | # calculate the expected heterozygosity for just one marker
expected_heterozygosity(ft_popstr_algeria_mzab_mozabite, "CSF1PO")
# calculate the expected heterozygosities for every marker
expected_heterozygosity(ft_popstr_algeria_mzab_mozabite)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.