Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

kinship2grm

Converts a kinship matrix to a Genetic Relation Matrix (GRM)


Description

Converts a kinship matrix to a Genetic Relation Matrix (GRM)

Usage

kinship2grm(x)

Arguments

x

a square matrix containing kinship coefficients

Details

for off-diagonal elements, GRM=2 \times x_{ij}; for diagonal elements, GRM=1+ x_{ii}

Value

a GRM matrix

Author(s)

Jerome Goudet jerome.goudet@unil.ch

Examples

## Not run: 
dos<-matrix(sample(0:2,replace=TRUE,size=1000),nrow=10) #dosage matrix for 10 inds at 100 loci
ks<-beta.dosage(dos) # kinship matrix
kinship2grm(ks)

## End(Not run)

hierfstat

Estimation and Tests of Hierarchical F-Statistics

v0.5-10
GPL (>= 2)
Authors
Jerome Goudet [aut, cre], Thibaut Jombart [aut], Zhian N. Kamvar [ctb], Eric Archer [ctb], Olivier Hardy [ctb]
Initial release
2021-11-16

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.