Learn R Programming

CAnD (version 1.4.0)

CAnD: Peform the CAnD Test

Description

Perform the CAnD test on a set of ancestry proportions estimated for a particular ancestral subpopulation of interest

Usage

CAnD(chrAncest, bonfCorr = TRUE)

Arguments

chrAncest
A data.frame holding the ancestral proportions; each row corresponds to a sample and each column corresponds to a chromosomal/chromosomal segment ancestry proportion. Note: only include the proportions for one ancestral population at a time.
bonfCorr
A logical argument indicating whether the p-value should be corrected for multiple testing using Bonferroni correction. The default is TRUE.

Value

A CAnDResult object holding the p-value for each chromosome/chromosomal segment, the overall CAnD p-value, the CAnD statistic and whether the Bonferroni multiple testing correction was used.

References

McHugh, C., Brown, L., Thornton, T. Detecting heterogeneity in population structure across chromosomes in admixed populations. Manuscript in Preparation.

Examples

Run this code
data(ancestries)
euroCols <- grep("Euro",colnames(ancestries))
euro <- ancestries[,euroCols]
res <- CAnD(euro)
res

Run the code above in your browser using DataLab