Gst: Estimation Nei's Gst parameter

View source: R/gst.R

GstR Documentation

Estimation Nei's Gst parameter

Description

This function estimates Nei's Gst parameter and potentially returns the components of it as well as the probability. The results are returned as a data.frame.

Usage

Gst(x, stratum = "Population", nperm = 0, size.correct = TRUE)

Arguments

x

A vector of locus objects or a data.frame with locus objects.

stratum

Either a vector of strata variables if x is a locus vector or the name of the column representing strata in x if it is a data.frame.

nperm

The number of permutations to run for significance of the estimator.

size.correct

A flag indicating that the estimate should be corrected for based upon sample sizes (default=TRUE).

Value

An data.frame with Gst, Ht, and Hs and optionally P

Author(s)

Rodney J. Dyer rjdyer@vcu.edu

Examples

 AA <- locus( c("A","A") )
 AB <- locus( c("A","B") )
 BB <- locus( c("B","B") )
 locus <- c(AA,AA,AA,AA,BB,BB,BB,AB,AB,AA)
 Population <- c(rep("Pop-A",5),rep("Pop-B",5))
 Gst( locus, Population, nperm=99 )
 locus2 <- c(AB,BB,AA,BB,BB,AB,AB,AA,AA,BB)
 df <- data.frame( Population, TPI=locus, PGM=locus2 )
 Gst( df, nperm=99)

dyerlab/gstudio documentation built on Feb. 2, 2024, 8:24 p.m.