Subsets a pyRAD.loci object

Description

This function returns a dataset (at this point, only in DNAStringSet format) from a pyRAD.loci, subsetting by loci and taxa provided as arguments

Usage

1
2
3
## S3 method for class 'pyRAD.loci'
subset(x, loci, taxa, format = "DNAStringSet", reportInterval = 500,
       nucVarType = c("verystrict", "strict", "relaxed"), ...)

Arguments

x

an object of class pyRAD.loci

loci

a character vector of loci to include

taxa

a character vector of taxa to include

format

format for DNA matrix; at this point, only DNAStringSet is supported

reportInterval

interval (number of loci) for reporting progress

nucVarType

nucleotide variability to consider in screening for polymorphism: 'relaxed' for all nucleotides, including ambiguities other than 'N', and counting all variable sites; 'strict' for only A,C,G,T, still counting all variable sites; and 'verystrict' for only A,C,G,T, countin only parsimony- informative sites.

...

not currently used, but left for compatibility with generic subset

Details

Probably it would make sense to wrap some of the functioning of gen.RAD.loci.datasets into this function, but for now they are separated.

Value

A list with values:

DNA

a list of datasets, one per locus, defined by format argument

variable

a boolean vector, indicating which loci are variable according to the criterion provided in arguments

ntaxa

an integer vector, indicating how many taxa are in each locus

Author(s)

Andrew Hipp

See Also

gen.RAD.loci.datasets, filter.by

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.