summary.SFS_class: Summary statistics

Description Usage Arguments Value See Also Examples

View source: R/summary_SFS_class.R

Description

Calculates summary statistics useful for analyzing DNA.

Usage

1
2
## S3 method for class 'SFS_class'
summary(SFS)

Arguments

SFS

vector with the site frequency spectrum of class 'SFS_class'.

Value

List containing the following components:

Watterson

Watterson's estimator.

pairwDiff

The pairwise difference estimator.

TajimaD

Tajima's D

See Also

mutRate, TajimaD

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
# Using the function SFS:
DNAmat <- matrix(c(0,1,0,0,
                   0,1,0,1,
                   0,0,0,0,
                   0,0,0,0), 4,4, byrow=TRUE)
summary(SFS(DNAmat))

# Creating SFS by hand:
SFS <- c(2,1,0,0,0,1,0,0)
class(SFS) <- "SFS_class"
summary(SFS)

aumath-advancedr2019/simDNA documentation built on Nov. 27, 2019, 11 a.m.