View source: R/outflank_input_freqs.R
outflank_input_freqs | R Documentation |
OutFLANK
inputConverts a long format data table of allele frequency information into a data frame fit for analysis by OutFLANK (Whitlock & Lotterhos 2015).
outflank_input_freqs(
dat,
popCol = "POP",
locusCol = "LOCUS",
freqCol = "FREQ",
indsCol = "INDS",
HoCol = NULL
)
dat |
Data table: The biallelic allele frequency data. Requires the following columns:
|
popCol |
Character: The column name with the sampled individual information. Default = |
locusCol |
Character: The column name with the locus information. Default = |
freqCol |
Character: The column name with the allele frequency information. Default = |
indsCol |
Character: The column name with the number of individuals (sample size)
used to estimate the allele frequency. Default = |
HoCol |
Character: An optional argument. The column name with the observed number of
heterozygotes. Affects estimation of FST, see details. Default = |
FST is estimated using modified versions of the OutFLANK
functions
WC_FST_FiniteSample_Diploids_2Alleles_NoCorr()
and WC_FST_FiniteSample_Diploids_2Alleles()
.
The observed heterozygosity, Ho, is required to calculate the variance components. However,
allele frequencies alone do not carry this information. Users can specify a column
containing the Ho (argument HoCol
) if this is known, otherwise, a naive assumption
that Ho = He (the expected heterozygosity) is made.
A data frame in the required format for analysis by OutFLANK
.
Whitlock & Lotterhos (2015) Reliable detection of loci responsible for local adaptation: Inference of a null model through trimming the distribution of FST. The American Naturalist 186.
library(genomalicious)
data(data_PoolFreqs)
data_PoolFreqs
ofDF <- outflank_input_freqs(
dat=data_PoolFreqs,
popCol='POOL',
locusCol='LOCUS',
freqCol='FREQ',
indsCol='INDS')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.