Learn R Programming

GWASTools (version 1.18.0)

missingGenotypeBySnpSex: Missing Counts per SNP by Sex

Description

For all SNPs for each sex tabulates missing SNP counts, allele counts and heterozygous counts.

Usage

missingGenotypeBySnpSex(genoData, scan.exclude = NULL, verbose = TRUE)

Arguments

genoData
GenotypeData object.
scan.exclude
A vector containing the scan numbers of scans that are to be excluded from the total scan list.
verbose
Logical value specifying whether to show progress information.

Value

This function returns a list with three components: "missing.counts," "scans.per.sex," and "missing.fraction."
missing.counts
A matrix with one row per SNP and one column per sex containing the number of missing SNP counts for males and females, respectively.
scans.per.sex
A vector containing the number of males and females respectively.
missing.fraction
A vector containing the fraction of missing counts for each SNP, with females excluded for the Y chromosome.

Details

This function calculates the fraction of missing genotypes for males and females for each SNP given in genoData. A "sex" variable must be present in the scan annotation slot of genoData.

See Also

GenotypeData, missingGenotypeByScanChrom

Examples

Run this code
library(GWASdata)
file <- system.file("extdata", "illumina_geno.gds", package="GWASdata")
gds <- GdsGenotypeReader(file)

# need scan annotation with sex
data(illuminaScanADF)
genoData <-  GenotypeData(gds, scanAnnot=illuminaScanADF)

missingRate <- missingGenotypeBySnpSex(genoData)
close(genoData)

Run the code above in your browser using DataLab