Learn R Programming

poolABC (version 1.0.0)

getFst: Calculate FST

Description

This function computes FST according to Hudson's estimator following Bathia. Note that the frequencies for the two populations should be entered as separate inputs.

Usage

getFst(freq1, freq2, ss1, ss2)

Value

a numeric value which is the FST between the two populations.

Arguments

freq1

is a numeric vector with the allele frequencies for population

  1. Each entry of the vector should be a different site.

freq2

is a numeric vector with the allele frequencies for population 2. Each entry of the vector should be a different site.

ss1

vector with the sample size for population 1. Each entry of the vector should contain the number of reads for a different site.

ss2

vector with the sample size for population 2. Each entry of the vector should contain the number of reads for a different site.

Details

Note that this functions computes a single FST value between two populations and does not perform pairwise comparisons of multiple populations.