makeA: Makes the A matrix for a part of a pedigree

View source: R/drivers.r

makeAR Documentation

Makes the A matrix for a part of a pedigree

Description

Makes the A matrix for a part of a pedigree and stores it in a file called A.txt.

Usage

makeA(ped,which)

Arguments

ped

data.frame with three columns: id,id parent1,id parent2

which

Logical vector specifying between which indiduals additive genetic relationship is required. Goes back through the whole pedigree but only for subset of individuals.

Value

Logical.

Examples

id <- 1:6
dam <- c(0,0,1,1,4,4)
sire <- c(0,0,2,2,3,5)
ped <- data.frame(id,dam,sire)
makeA(ped,which = c(rep(FALSE,4),rep(TRUE,2)))
A <- read.table("A.txt")

if(file.exists("A.txt"))
file.remove("A.txt")

pedigree documentation built on Aug. 14, 2022, 1:06 a.m.