Rousset: Rousset relatedness coefficient Matrix

Description Usage Arguments Details Value Author(s) References Examples

View source: R/bm_rousset.r

Description

Compute the Rousset relatedness coefficient Matrix

Usage

1
 Rousset(x, which.snps, het_het=0.5, share_het_het=1, autosome.only = TRUE, chunk = 1L) 

Arguments

x

A bed.matrix

which.snps

Logical vector, giving which snps to use in the computation. The default is to use all autosomal SNPs

het_het

Proportion value of identical variants between pairs of heterozygous individuals

share_het_het

Number of alleles sharing between pairs of heterozygous individuals

autosome.only

If TRUE, only autosomal SNPs will be considered.

chunk

Parameter for the parallelization: how many SNPs are treated by each task

Details

The Rousset relatedness coefficient between two individuals i and j, is defined as R_{ij}=\frac{Q_{ij}- Q_m}{1-Q_m} where Q_{ij} is the proportion of variants which are identical by state between the two individuals and Q_m is the mean proportion of variants which are identical by state in the population. At a given SNP, the proportion of identical variants for a given pair of individuals was set to 0 if both individuals were homozygous and carrying a different allele (e.g. 00 and 11), 1 if both individuals were homozygous and carrying the same allele (e.g. 00 and 00), het_het for pairs of heterozygous individuals (e.g. 01 and 01) and 0.5 in all others cases.

Value

A list of seven.

Rousset element is the Rousset relatedness coefficient Matrix which is a symmetric square matrix of dimension equal to the number of individuals.

F element contains the matrix of Q_{ij} values given in details section.

Qm element is the Q_m value given in details section.

Nsnp element is a symmetric square matrix of dimension equal to the number of individuals which contains the number of SNPs available by pairs

SHare0 element is the Matrix of SNP proportion sharing 0 allele between two individuals which is a symmetric square matrix of dimension equal to the number of individuals

SHare1 element is the Matrix of SNP proportion sharing 1 allele between two individuals which is a symmetric square matrix of dimension equal to the number of individuals. By default, pairs of heterozygous individuals are considered to share 1 allele.

SHare2 element is the Matrix of SNP proportion sharing 2 alleles between two individuals which is a symmetric square matrix of dimension equal to the number of individuals

Author(s)

Claire Dandine-Roulland

References

Rousset, F, 2002, Inbreeding and relatedness coefficients: what do they measure?, Heredity 88(5), 371-380

Examples

1
2
3
4
5
6
7
# load chr2 data set (~10k SNPs in low LD)
x <- read.bed.matrix( system.file("extdata", "chr2.bed", package="gaston") )

# Compute Rousset Relationship Matrix
K <- Rousset(x)
str(K)
dim(K)

genostats/gaston.pop documentation built on Jan. 17, 2022, 10:58 a.m.