QstFstComp: Compare Qst to Fst

Description Usage Arguments Author(s) References Examples

Description

Compares the QST of a single phenotypic trait to the mean FST of series of marker loci. It calculates the distribution of QST - FST under a model assuming neutrality of both the phenotypic trait and the genetic markers from which FST is estimated. Returns the simulated estimates of Qst - Fst under neutrality following the procedure described in Gilbert and Whitlock (2014) and Whitlock & Guillaume (2009). Also returns the simulated estimates of Fst and Qst used to compute the null distribution.

Usage

1
2
QstFstComp(fst.dat, qst.dat, numpops, nsim = 1000, AFLP = FALSE,
  breeding.design, dam.offspring.relatedness = 0.25, output = "concise")

Arguments

fst.dat

A data frame with the first column indicating population of origin and the following columns representing genotypes at loci; see the README https://github.com/kjgilbert/QstFstComp/blob/master/README.md for further description. If using AFLPs, this is a data frame of q-hat values, with pops in columns, loci in rows and the corresponding q-hat variances in the following columns, and AFLP=TRUE must be designated.

qst.dat

the input table of the breeding data

  • For breeding.design = "half.sib.sire": qst.dat should have four columns in this order: population, sire, dam, and the trait value of the individual. Each population, sire, and dam should have unique names or numbers.

  • For breeding.design = "half.sib.dam": qst.dat should have three columns in this order: population, dam, and the trait value of the individual. Each population and dam should have unique names or numbers.

numpops

number of populations in the sample

nsim

number of simulation replicates to perform to create the null distributions and bootstraps

@param AFLP whether or not to use AFLP data

@param breeding.design the breeding design used when collecting the trait data There are two options for breeding design:

  1. "half.sib.sire" is a half sib design with dam nested within sire nested within population which works for either balanced or unbalanced sampling designs

  2. "half.sib.dam" is a half sib design with dam nested within population which works for either balanced or unbalanced sampling designs

@param dam.offspring.relatedness relatedness between offspring in the dam model, default is 1/4, i.e. half-sib

@param output whether to output full, concise, or without writing out vector of resampled Q-F values, see details below

@return

Returns either a concise list of a subset of results or a full list with all possible results. Both output options write the vector of Qst-Fst values to a text file unless "_nowrite" is appended to the option, e.g. "concise_nowrite" returns only the concise output without writing output to a text file.

Concise list returns (default)

  • the calculated difference between Qst and Fst with 95% critical values,

  • one- and two- tailed p-values for this difference,

  • the Fst value estimated from the data with 95% confidence intervals,

  • the Qst value estimated from the data with 95% confidence intervals, and

  • the additive genetic variance for the trait with 95% confidence intervals

Full list returns

  • the calculated difference between Qst and Fst with 95% critical values,

  • one- and two- tailed p-values for this difference,

  • a list of all Qst-Fst values for plotting the distribution of Qst-Fst,

  • the Fst value estimated from the data with 95% confidence intervals,

  • the resampled Fst as calculated from bootstrapping across simulations, with standard deviation and 95% confidence intervals,

  • a list of all resampled Fst values for plotting the distribution of Fst,

  • the Qst value estimated from the data with 95% confidence intervals,

  • the resampled neutral Qst as calculated from bootstrapping across simulations, with standard deviation and 95% critical values,

  • a list of all resampled Qst values for plotting the distribution of the neutral Qst,

  • the ANOVA table for the calculated means squared, n coefficients, and degrees of freedom,

  • the additive genetic variance for the trait with 95% confidence intervals, and

  • the coefficient of additive genetic variance for the trait with 95% confidence intervals

Be mindful of the fact that with a small number of loci, bootstrapped confidence intervals of Fst can be less accurate.

Author(s)

Kimberly J Gilbert & Michael C Whitlock

References

Gilbert KJ and MC Whitlock (2015) Qst Fst comparisons with unbalanced half-sib designs. Molecular Ecology Resources, 15(2), 262-267.

Whitlock MC and F Guillaume (2009) Testing for spatially divergent selection: Comparing Qst to Fst. Genetics, 183:1055-1063.

Examples

1
2
3
4
5
6
7
8
## using balanced half-sib sire trait data and biallelic marker data 
data(hssire) # trait data
data(biallelic) # marker data
QstFstComp(biallelic, hssire, numpops=15, nsim=100, breeding.design="half.sib.sire", output="full")

data(hsdam)
data(aflp)
QstFstComp(aflp, hsdam, numpops=15, nsim=100, AFLP=TRUE, breeding.design="half.sib.dam", output="concise")

kjgilbert/QstFstComp documentation built on May 20, 2019, 10:25 a.m.