Xfix: function to set impossible genotypes as missing

Description Usage Arguments Details Value Author(s) See Also Examples

Description

Sets impossible genotypes (e.g. heterozygous male X-linked genotypes) to missing

Usage

1

Arguments

data

Object of gwaa.data-class

Details

Sets to missing genotypes in the following situations: (1) heterozygous male X-genotypes (2) heterozygous Y- and mtDNA genotypes (3) any Y-genotypes in females. Should only be used after check.marker, which identifies systematic sex errors.

Value

The same object of gwaa.data-class, with fixed genotypes

Author(s)

Yurii Aulchenko

See Also

check.marker

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
require(GenABEL.data)
data(ge03d2c)
# truncate the data to make the example faster
ge03d2c <- ge03d2c[seq(from=1,to=nids(ge03d2c),by=2),seq(from=1,to=nsnps(ge03d2c),by=2)]
# many errors
mc0 <- check.marker(ge03d2c)
# take only people and markers passing QC
fixed0 <- ge03d2c[mc0$idok,mc0$snpok]
# major errors fixed, still few males are heterozygous for X-chromsome markers
mc1 <- check.marker(fixed0)
# fix minor X-chromosome problems
fixed1 <- Xfix(fixed0)
# no errors
mc2 <- check.marker(fixed1)
summary(mc2)

GenABEL documentation built on May 30, 2017, 3:36 a.m.

Related to Xfix in GenABEL...