Description Usage Arguments Details Value
Calculates log-likelihood for a pair of samples at a single locus.
1 2 3 | probUxUy(Ux, Uy, nx, ny, probs, reval)
probUxUyEqr(Ux, Uy, nx, ny, probs, rval, nm)
|
Ux, Uy |
sets of unique alleles for two samples at a given locus. Vectors
of indices corresponding to ordered probabilities in |
nx, ny |
complexity of infection for two samples. Vectors of length 1. |
probs |
a vector of population allele frequencies at a given locus. (Should sum to one - not checked!) |
reval |
a matrix containing the grid of {r} combinations, over which the likelihood is to be calculated. Each column represents a single combination. |
rval |
a vector of r values, over which the likelihood is to be calculated. |
nm |
the number of related strains. |
probUxUyEqr
is used for a special case when all pairs of
strains are assumed to be related with the same parameter r. For that
case, fast calculations are performed, and the results are equivalent to
the general case with each value of rval
is repeated nm
times.
A vector of log-likelihood values for each evaluated {r}
combination (or a value for probUxUyEqr
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.