50% off: Unlimited data and AI learning.
State of Data and AI Literacy Report 2025

forrel (version 1.2.0)

kappaBootstrap: Bootstrap estimation of IBD coefficients

Description

These functions produce (parametric) bootstrap estimates of the IBD coefficients between two individuals. Both kappa coefficients (for noninbred individuals) and the 9 condensed identity coefficients are supported.

Usage

kappaBootstrap(kappa, N, freqList, plot = TRUE)

deltaBootstrap(delta, N, freqList)

Arguments

kappa, delta

A probability vector of length 3 (kappa) or 9 (delta): The coefficients under which simulations are performed.

N

The number of simulations.

freqList

A list of probability vectors: The allele frequencies for each marker.

plot

A logical. If TRUE, the bootstrap kappa estimates are plotted in the IBD triangle.

Value

A data frame with N rows containing the bootstrap estimates. The last column (dist) gives the euclidean distance to the input, viewed as a point in R^3 (kappa) or R^9 (delta).

Details

In each replication, profiles for two individuals are simulated under the input coefficients, and their relationship is re-estimated with ibdEstim().

Examples

Run this code
# NOT RUN {
# Frequency list of 15 standard STR markers
freqList = NorwegianFrequencies[1:15]

# Number of bootstrap simulations (increase!)
N = 5

# Bootstrap estimates for kappa of full siblings
boot1 = kappaBootstrap(c(0.25, .5, .25), N = N, freqList = freqList)
boot1

# Mean deviation
mean(boot1$dist)

# Same, but with the 9 identity coefficients.
delta = c(0, 0, 0, 0, 0, 0, .25, .5, .25)
boot2 = deltaBootstrap(delta, N = N, freqList = freqList)

# Mean deviation
mean(boot2$dist)

# }

Run the code above in your browser using DataLab