CheckAndReturnDBSMatrix: Check and return the DBS mutation matrix

CheckAndReturnDBSMatrixR Documentation

Check and return the DBS mutation matrix

Description

Check and return the DBS mutation matrix

Usage

CheckAndReturnDBSMatrix(
  vcf,
  discarded.variants,
  mat78,
  mat136,
  mat144 = NULL,
  return.annotated.vcf = FALSE,
  sample.id = "counts"
)

Arguments

vcf

An in-memory VCF file annotated with sequence context and transcript information by function AnnotateDBSVCF. It must *not* contain indels and must *not* contain SBS (single base substitutions), or triplet base substitutions etc.

discarded.variants

A data.frame which contains rows of DBS variants whose tetranucleotide context contains "N".

mat78

The DBS78 mutation count matrix.

mat136

The DBS136 mutation count matrix.

mat144

The DBS144 mutation count matrix.

return.annotated.vcf

Whether to return the annotated VCF with additional columns showing the mutation class for each variant. Default is FALSE.

sample.id

Usually the sample id, but defaults to "count".

Value

A list of three 1-column matrices with the names catDBS78, catDBS136, and catDBS144. If trans.ranges is NULL, catDBS144 is not generated. Do not rely on the order of elements in the list. If return.annotated.vcf = TRUE, another element annotated.vcf will appear in the list. If there are DBS variants whose tetranucleotide context contains "N", they will be excluded in the analysis and an additional element discarded.variants will appear in the return list.


ICAMS documentation built on June 22, 2024, 6:47 p.m.