nucleotideDiversity: Nucleotide Diversity

Description Usage Arguments Value Author(s) Examples

View source: R/nucleotideDiversity.R

Description

Calculate nucleotide diversity for set of haplotypes.

Usage

1
nucleotideDiversity(x, bases = c("a", "c", "g", "t"), simplify = TRUE)

Arguments

x

a set of sequences or a gtypes object with sequences.

bases

nucleotides to consider when calculating diversity.

simplify

if TRUE and only one loci exists, return a vector, otherwise, a list of vectors with one element per locus will be returned.

Value

Vector of nucleotide diversity by site.

Author(s)

Eric Archer eric.archer@noaa.gov

Examples

1
2
3
4

strataG documentation built on Feb. 28, 2020, 9:07 a.m.