resetSamFilter | R Documentation |
setSamFilter()
Remove "invalid" labels put on samples and make all samples valid.
resetSamFilter(object, ...)
## S4 method for signature 'GbsrGenotypeData'
resetSamFilter(object)
object |
A GbsrGenotypeData object. |
... |
Unused. |
A GbsrGenotypeData object after removing all filters on samples.
# Create a GDS file from a sample VCF file.
vcf_fn <- system.file("extdata", "sample.vcf", package = "GBScleanR")
gds_fn <- tempfile("sample", fileext = ".gds")
gbsrVCF2GDS(vcf_fn = vcf_fn, out_fn = gds_fn, force = TRUE)
# Load data in the GDS file and instantiate a [GbsrGenotypeData] object.
gds <- loadGDS(gds_fn)
# Summarize the information needed for filtering.
gds <- countGenotype(gds)
gds <- countRead(gds)
gds <- setSamFilter(gds,
id = getSamID(gds)[1:10],
missing = 0.2,
dp = c(5, Inf))
# Reset all filters applied above.
gds <- resetSamFilter(gds)
# Close the connection to the GDS file
closeGDS(gds)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.