calcGjoint | R Documentation |
getGlist Returns a list of joint genotypes with corresponding joing probabilities for unknowns contributors for a given marker.
calcGjoint(freq, nU = 1, fst = 0, refK = NULL, refR = NULL, ibd = c(1, 0, 0))
freq |
A vector of allele frequencies for a given population. |
nU |
Number of unknowns (where the LAST is a related) |
fst |
Assumed theta/fst-correction |
refK |
contains a vector of alleles for the known typed reference profiles (a,b,c,d...) |
refR |
contains a vector of alleles for a related reference profile (a,b) |
ibd |
the identical by decent coefficients of the relationship denotation |
The function returns the list of all possible genotypes, with corresponding probabilities. The allele-names in popFreq needs to be numbers. If a related unknown is provided that will always be the first one
Glist A list with genotypes and genotype probabilities
Oyvind Bleka
freq = rgamma(8,1,1)
freq = stats::setNames(freq/sum(freq),1:length(freq))
foo1 = calcGjoint(freq,nU=2,fst=0.1,refK=c("2","3","1","1"))
foo2 = calcGjoint(freq,nU=2,fst=0.1,refK=c("2","3","1","1"),
refR=c("2","3"),ibd=c(1/4,1/2,1/4))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.