Description Details Constructors Accessors Methods Author(s) References See Also Examples
S4 class for storing information about variants
This class extends the class GRanges without
adding any extra slots. The main difference is that VariantInfo
objects always have a metadata column “MAF” that contains
minor allele frequencies (MAFs). A special
summary method allows for computing statistics about
MAFs and types of variants.
Objects of this class should only be created and manipulated by the constructors and accessors described below, as only these methods ensure the integrity of the created objects. Direct modification of object slots is strongly discouraged!
signature(x="missing"):
creates an empty VariantInfo object
signature(x="GRanges"):
coerces a GRanges object to class
VariantInfo by adding a “MAF” metadata column that
is initialized with NA values.
Furthermore, see the help page of readVariantInfo.
signature(object="VariantInfo"):
returns a numeric vector with the minor allele frequencies (MAFs).
signature(object="VariantInfo"):
returns a string with the number of variants and metadata columns
(if any); if the optional argument details is set to
TRUE, this method computes and prints a summary about the
MAFs and variant types (if available); this variant returns a
list with summarized values.
All other methods, including sub-setting, are inherited from the
GRanges class.
Ulrich Bodenhofer bodenhofer@bioinf.jku.at
http://www.bioinf.jku.at/software/podkat
GRanges, readVariantInfo,
genotypeMatrix, readGenotypeMatrix
1 2 3 4 5 6 7 8 9 10 11 12 | vcfFile <- system.file("examples/example1.vcf.gz", package="podkat")
## read variant info directly from VCF file
vInfo <- readVariantInfo(vcfFile, omitZeroMAF=FALSE)
vInfo
summary(vInfo)
## read full genotype from VCF file
geno <- readGenotypeMatrix(vcfFile)
## display summary of variant info stored in genotype matrix
summary(variantInfo(geno))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.