app.unpairs: Relatedness excepted given pairs

Description Usage Arguments Value Author(s) See Also Examples

View source: R/app_pairs.r

Description

Removed given pairs from relatedness matrix and apply given function

Usage

1

Arguments

app

Relatedness matrix

unpairs

Vector or matrix defining wanted pairs or a list of such elements

FUN

Function to apply to relatedness of individulas excepted for given pairs. Argument function must be a vector.

Value

Result value of FUN function for relatedness of individuals pairs excepted for given pairs.

Author(s)

Claire Dandine-Roulland

See Also

app.pairs

Examples

1
2
3
4
5
6
7
8
# 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)$Rousset

# Cmmpute mean of relatedness between individuals from different population
app.unpairs(K, x@ped$population, FUN=mean)

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