Skip to contents

Extract only baseline-tier annotations from an AnnotationMatrix.

Usage

getBaseline(annot)

Arguments

annot

An AnnotationMatrix object.

Value

An AnnotationMatrix with only baseline annotations.

Examples

snpRanges <- GenomicRanges::GRanges(
  "22", IRanges::IRanges((1:10) * 100, width = 1))
annotations <- matrix(rbinom(50, 1, 0.3), 10, 5,
  dimnames = list(NULL, paste0("annot", 1:5)))
meta <- data.frame(name = paste0("annot", 1:5), tier = "baseline",
  type = "binary")
am <- AnnotationMatrix(annotations, snpRanges, annotationMeta = meta)
getBaseline(am)
#> AnnotationMatrix: 10 SNPs x 5 annotations
#>   Baseline: 5, Candidate: 0
#>   Binary: 5, Continuous: 0
#>   Genome build: hg19