Learn R Programming

rehh (version 2.0.4)

ies2xpehh: Compute XP-EHH (standardized ratio of iES from two populations) as described in Sabeti et al. (2007)

Description

Compute XP-EHH (standardized ratio of iES from two populations) as described in Sabeti et al. (2007).

Usage

ies2xpehh(hh_pop1, hh_pop2, popname1 = NA, popname2 = NA,
            method = "bilateral")

Arguments

hh_pop1

A matrix with nsnps rows and six columns (Chromosome name, position of the SNP, Frequency of the ancestral allele, iHH for the ancestral allele, iHH for the derived allele and iES) obtained after performing a scan on the first population.

hh_pop2

A matrix with nsnps rows and six columns (Chromosome name, position of the SNP, Frequency of the ancestral allele, iHH for the ancestral allele, iHH for the derived allele and iES) obtained after performing a scan on the second population.

popname1

Name of the first population compared (character string).

popname2

Name of the second population compared (character string).

method

Either "bilateral" or "unilateral". If bilateral (resp. unilateral), the pvalue (assuming XP-EHH follows a standard Gaussian distribution under neutrality) corresponds to a bilateral (resp. unilateral) tests

Value

The returned value is a matrix with nsnps rows and four columns (Chromosome name, position of the SNP, XP-EHH and Pvalue)

Details

Ratio of iES (population 1 over population 2) computed and standardized as described in Sabeti et al. (2007)

References

Gautier, M. and Naves, M. (2011). Footprints of selection in the ancestral admixture of a New World Creole cattle breed. Molecular Ecology, 20, 3128--3143.

Sabeti, P.C. et al. (2007). Genome-wide detection and characterization of positive selection in human populations. Nature, 449, 913--918.

See Also

calc_ehhs,scan_hh,distribplot,rsbplot

Examples

Run this code
# NOT RUN {
data(wgscan.cgu) ; data(wgscan.eut)
## results from a genome scan (44,057 SNPs)
##see ?wgscan.eut and ?wgscan.cgu for details
xpehh<-ies2xpehh(wgscan.cgu,wgscan.eut,"CGU","EUT")
# }

Run the code above in your browser using DataLab