get.pedindex: Get pedigree index.

Description Usage Arguments Details Value Examples

Description

get.pedindex returns indices of individuals in the pedigree.

Usage

1
get.pedindex(pedinfo, member.set)

Arguments

pedinfo

dataframe.

member.set

character vector.

Details

member.set contains member IDs of individuals of interest.

Value

An integer vector of indices for each individual of interest found in pedinfo.

Examples

1
2
3
4
5
6
7
8
9
# a simple pedigree with sibling marriage
pedigree = as.character(rep(1, 5))
member = as.character(c(11, 12, 21, 22, 31))
sex = as.numeric(c(1, 2, 1, 2, 1))
father = as.character(c(NA, NA, 11, 11, 21))
mother = as.character(c(NA, NA, 12, 12, 22))
pedinfo = data.frame(pedigree, member, sex, father, mother, stringsAsFactors = FALSE)

get.pedindex(pedinfo, c("22", "31"))

bowenwang7/r3 documentation built on May 17, 2019, 6:39 p.m.