computeG | R Documentation |
Use single nucleotide polymorphisms markers to derive an additive genomic relationship matrix. Missing markers are allowed, but should be coded as NA.
computeG(snpmatrix, maf = 0.05, impute = "rbinom", method = "G1")
snpmatrix |
A marker matrix with the dimension of n by m, where the elements are coded as 0, 1, 2, or NA, where n and m are the total number of individuals and markers, respectively. |
maf |
A minor allele frequency cutoff for quality control. The default minor allele frequency is 0.05. |
impute |
Perform genotype imputation for missing markers if applicable. Two methods of 'mean' and 'rbinom' are available,
where the 'mean' imputes missing markers using mean and 'rbinom' imputes the missing markers by random sampling from
a binomial distribution. The default method is 'rbinom'. This argument will be ignored if the |
method |
A type of genomic relationship matrix including 'G1' and 'G2' (VanRaden 2008). The default method is 'G1'. |
An n by n additive genomic relationship matrix.
Haipeng Yu and Gota Morota
Maintainer: Haipeng Yu haipengyu@vt.edu
VanRaden, P.M., 2008. Efficient methods to compute genomic predictions. Journal of dairy science, 91(11), pp.4414-4423.
# Load cattle data
data(GCcattle)
# Marker information
str(cattle.W)
# Compute genomic relationship matrix
G <- computeG(cattle.W, maf = 0.05, impute = 'rbinom', method = 'G1')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.