Skip to contents

$$G = ZZ^T / (2 \sum_j p_j(1-p_j))$$ with \(Z_{ij} = M_{ij} - 2p_j\). VanRaden (2008) method 1; the same matrix is MVSML (2022) method 2, p.51, whose printed example is reproduced exactly by this function.

Usage

Vanr1(marker_matrix, freq = NULL)

Arguments

marker_matrix

Lines by markers, coded 0, 1, 2.

freq

Optional allele frequencies; column means over 2.

Value

Named list with estimate, G, freq, denominator, n_lines, n_markers, method.

References

VanRaden (2008) J Dairy Sci 91:4414-4423.

Examples

Vanr1(matrix(c(1, 0, 0, 1, 2, 1), nrow = 2))
#> $estimate
#> [1] 0.6666667
#> 
#> $G
#>            [,1]       [,2]
#> [1,]  0.6666667 -0.6666667
#> [2,] -0.6666667  0.6666667
#> 
#> $freq
#> [1] 0.25 0.25 0.75
#> 
#> $denominator
#> [1] 1.125
#> 
#> $n_lines
#> [1] 2
#> 
#> $n_markers
#> [1] 3
#> 
#> $method
#> [1] "VanRaden (2008) method 1 genomic relationship matrix"
#>