outflank_mod_fst_nocorrect: Modificatin of OutFLANK's...

View source: R/outflank_mod_fst_nocorrect.R

outflank_mod_fst_nocorrectR Documentation

Modificatin of OutFLANK's WC_FST_FiniteSample_Diploids_2Alleles_NoCorr()

Description

Skip the need for diploid genotypes, i.e. just use allele frequencies, and produce the same output as WC_FST_FiniteSample_Diploids_2Alleles_NoCorr(). Calculate FST without a sample size correction.

Usage

outflank_mod_fst_nocorrect(alleleFreqs, sampSize, Ho)

Arguments

alleleFreqs

Numeric: A vector of the Reference allele frequency, with the length == number of populations.

sampSize

Integer: A vector of sample sizes, with the length == number of populations and the order corresponding to the those in alleleFreqs.

Ho

Integer: An optional vector of the heterozygote frequency, with the length == number of populations and the order corresponding to the those in alleleFreqs. Default = NULL, see Details.

Details

By using just allele frequencies, there is no information about the observed frequency of heterozygotes, Ho. The function will make the naive assumption that Ho = He, if Ho is not specified.

Value

Returns a list of values related to FST:

  • He: the expected heterozygosity of the locus

  • FSTNoCorr: Fst (without sample size correction)

  • T1NoCorr: The numerator of the uncorrected sample size correction (similar to Weir and Cockerham 1984)

  • T2NoCorr: The denominator of the uncorrected sample size correction


j-a-thia/genomalicious documentation built on Oct. 19, 2024, 7:51 p.m.