DivSampleNum: DivSampleNum

Description Usage Arguments Details Value Author(s) References Examples

View source: R/DivE.R

Description

Function to generate an integer sequence representing the lengths of nested samples of sample

Usage

1
DivSampleNum(ms, n)

Arguments

ms

the main sample, either as a 2-column data.frame (species ID, count of species), or a vector of species IDs.

n

desired number of nested samples (integer)

Details

This function produces the default list of nested sample lengths for the DivE algorithm. For the vector representation of the main sample (ms) it is equivalent to sort(round(seq(from=length(ms)/n, to=length(ms), by=length(ms)/n)), decreasing=TRUE).

Value

A decreasing sequence of nested sample lengths.

Author(s)

Daniel J. Laydon, Aaron Sim, Charles R.M. Bangham, Becca Asquith

References

Laydon, D. J., Melamed, A., Sim, A., Gillet, N. A., Sim, K., Darko, S., Kroll, S., Douek, D. C., Price, D., Bangham, C. R. M., Asquith, B., Quantification of HTLV-1 clonality and TCR diversity, PLOS Comput. Biol. 2014

Examples

1
2
3
4
5

DivE documentation built on March 26, 2020, 7:38 p.m.