View source: R/genetic_covariance.R
| dist_from_biallelic | R Documentation |
Computes pairwise squared genetic distances from biallelic (SNP) allele
counts. This is a convenience wrapper for
dist_from_cov(cov_from_biallelic(Y, N)).
dist_from_biallelic(Y, N)
Y |
Numeric matrix of derived-allele counts (populations/individuals in rows, loci in columns). |
N |
Numeric matrix of haploid sample sizes with the same dimensions as
|
A symmetric numeric matrix of pairwise squared distances with zero
diagonal. Suitable for use with mlpe or
generalized_wishart.
cov_from_biallelic, dist_from_cov,
fst_from_biallelic
Y <- matrix(c(2, 1, 0,
1, 1, 1,
0, 1, 2), nrow = 3, byrow = TRUE)
N <- matrix(2, nrow = 3, ncol = 3)
dist_from_biallelic(Y, N)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.