dropInfo-methods | R Documentation |
Given a character
vector of INFO keys, removes either the associated
header, data, or both from a VCF
object.
If no INFO key is given (the default), all INFO keys are checked and removed
from the given slot if they do not have a matching entry in the other slot.
## S4 method for signature 'VCF'
dropInfo(
vcf, key = NULL, slot = "both")
vcf |
|
key |
If |
slot |
Should the INFO keys be removed from the "header", the "data",
or |
An integer
vector representing the aggregated count of the given
genotypes in each row.
In the future, x
should also support genotype quality (GQ) to consider
only genotypes above a given quality cut-off.
Kevin Rue-Albrecht
VCF
# Example data ----
# VCF file
vcfFile <- system.file("extdata", "moderate.vcf", package = "TVTB")
# TVTB parameters
tparam <- TVTBparam(Genotypes("0|0", c("0|1", "1|0"), "1|1"))
# Pre-process variants
vcf <- VariantAnnotation::readVcf(
vcfFile, param = tparam)
vcf <- VariantAnnotation::expand(vcf, row.names = TRUE)
# Example usage ----
dropInfo(vcf)
dropInfo(vcf, "CSQ")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.