chkPed {asreml} | R Documentation

## Check a pedigree

### Description

Checks a pedigree for consistency, adds missing founders and sorts so that founders appear before individuals.

### Usage

    chkPed(
      pedigree,
      fgen = list(character(0), 0.01),
      gender = character(0),
      mv = c("0", "*", " ")
    )

### Arguments

`pedigree` | A data frame where the first three columns correspond to the identifiers for the individual, male parent and female parent, respectively. The row giving the pedigree of an individual must appear before any row where that individual appears as a parent. Founders use 0 (zero) or NA in the parental columns.
`fgen` | An optional list of length 2 where `fgen[[1]]` is a character string naming the column in `pedigree` that contains the level of selfing or the level of inbreeding of an individual. In `pedigree[,fgen[[1]]]`, 0 indicates a simple cross, 1 indicates selfed once, 2 indicates selfed twice, etc. A value between 0 and 1 for a base individual is taken as its inbreeding value. If the pedigree has implicit individuals (they appear as parents but not as individuals), they will be assumed base non-inbred individuals unless their inbreeding level is set with `fgen[[2]]`, where `0 < fgen[[2]] < 1` is the inbreeding level of such individuals.
`gender` | An optional character string naming the column of `pedigree` that codes for the gender of an individual. `pedigree[, gender]` is coerced to a factor and must only have two (arbitrary) levels, the first of which is taken to mean "male". An inverse relationship matrix is formed for the X chromosome as described by Fernando and Grossman, 1990 for species where the male is XY and the female is XX.
`mv` | A character vector of missing value indicators; elements of `pedigree` that exactly match any of the members of `mv` are treated as missing.

### Value

The pedigree in a data frame, reordered and expanded if necessary.

[Package asreml version 4.1.0.176 Index]