read_assays_variants: Reading the assays of variants

View source: R/read.R

read_assays_variantsR Documentation

Reading the assays of variants

Description

read_assays_variants retrieves the assays of variants in an h5f.

Usage

read_assays_variants(
  h5f,
  included_assays = c("AF", "DP", "FILTER_MASK", "GQ", "NGT", "RGQ"),
  index_variants = NULL,
  index_cells = NULL,
  format = c("list", "RangedSummarizedExperiment")
)

Arguments

h5f

h5f

included_assays

A character vector. Selects which assays to retrieve. Possible values are

AF

variant allele frequencies (VAF) per cell and per variant

DP

read counts per cell and per variant

FILTER_MASK

binary value

GQ

genotype quality values per cell and per variant

NGT

genotypes per cell and per variant

  • 0 = Reference (Wildtype)

  • 1 = Heterozygous Mutant

  • 2 = Homozygous Mutant

  • 3 = Missing Data

RGQ

???

index_variants

A named numeric vector. You should use get_variants_index to retrieve the indexes.

index_cells

A numeric vector. Specifies which cells (columns) to retrieve.

format

A character. Specifies the return format. Either a list or a RangedSummarizedExperiment.

Value

Default is a named list. Can return a RangedSummarizedExperiment if specified.

Examples

#' #Retrieving the NGT matrix for IDH1_R132H and NPM1c
## Not run: 
interesting_variants <- c(IDH1_R132H = "chr2:209113112:C/T", NPM1c = "chr5:170837543:C/CTCTG")
index <- get_variants_index(h5f, interesting_variants)
read_dna_variants(h5f, index_variants = index, included_assays = "NGT")

## End(Not run)

northNomad/tapestri.tools documentation built on May 31, 2024, 4:44 p.m.