test.within: Tests the significance of the effect of inner.level on...

test.withinR Documentation

Tests the significance of the effect of inner.level on genetic differentiation within blocks defined by outer.level

Description

Tests the significance of the effect of inner.level on genetic differentiation within blocks defined by outer.level

Usage

test.within(data, within, test.lev, nperm, ...)

Arguments

data

a data frame containing the genotypes for the different loci

within

A vector containing the units in which to keep the observations

test.lev

A vector containing the units from which to construct the contingency tables

nperm

The number of permutations to carry out for the test

...

Mainly here to allow passing diploid=FALSE if necessary

Value

g.star

A vector containing all the generated g-statistics, the last one beeing the observed

p.val

The p-value associated with the test

Author(s)

Jerome Goudet jerome.goudet@unil.ch

Examples

data(gtrunchier)
attach(gtrunchier)
#tests whether the patch level has a significant effect on genetic structure
test.within(gtrunchier[,-c(1,2)],within=Locality,test.lev=Patch)

hierfstat documentation built on May 6, 2022, 1:05 a.m.