Learn R Programming

introgress (version 1.2.3)

delta: Delta

Description

This function calculates delta ($\delta$), the differential between allelic frequencies in two populations. It is called by the function prepare.data.

Usage

delta(SpA, SpB)

Arguments

SpA
a vector of population allele frequencies.
SpB
a vector of population allele frequencies.

Value

This function returns a vector of length one with the value of $\delta$.

Details

This function calculates the allele frequency differential for a pair of species or populations ($\delta$, Gregorius and Roberds 1986) for a single locus.

$$\delta = \sum_{i} \frac{|f_{i1} - f_{i2}|}{2}$$

where $f_{i1}$ and $f_{i2}$ denote the frequency of the ith allele in populations one and two, respectively. $\delta$ ranges from 0, for identical populations, to 1, for populations that share no alleles in common.

References

Gregorius, H. R. and Roberds, J. H. (1986) Measurement of genetical differentiation among subpopulations. Theoretical and Applied Genetics, 71, 826-834.

See Also

prepare.data

Examples

Run this code
## allele frequencies for two populations
pop.a<-c(0.3,0.5,0.2)
pop.b<-c(0.1,0.1,0.8)

## delta calculation
delta(pop.a,pop.b)

Run the code above in your browser using DataLab