Hs.test: Test differences in expected heterozygosity (Hs)

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

View source: R/Hs.R

Description

This procedure permits to test if two groups have significant differences in expected heterozygosity (Hs). The test statistic used is simply the difference in Hs between the two groups 'x' and 'y':

Usage

1
Hs.test(x, y, n.sim = 999, alter = c("two-sided", "greater", "less"))

Arguments

x

a genind object.

y

a genind object.

n.sim

the number of permutations to be used to generate the reference distribution.

alter

a character string indicating the alternative hypothesis

Details

Hs(x) - Hs(y)

Individuals are randomly permuted between groups to obtain a reference distribution of the test statistics.

Value

an object of the class randtest

Author(s)

Thibaut Jombart t.jombart@imperial.ac.uk

See Also

Hs to compute Hs for different populations; as.randtest for the class of Monte Carlo tests.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Not run: 
data(microbov)
Hs(microbov)
test <- Hs.test(microbov[pop="Borgou"],
                microbov[pop="Lagunaire"],
                n.sim=499)
test
plot(test)

## End(Not run)

adegenet documentation built on May 29, 2017, 5:54 p.m.

Search within the adegenet package
Search all R packages, documentation and source code