maf2spec: Construct the spectrum from a MAF file

View source: R/preprocess.R

maf2specR Documentation

Construct the spectrum from a MAF file

Description

The function converts a MAF file into a spectrum matrix which has mutation counts catalogued by contexts. It uses the fact that DNA has two complementary strands and folds the A/G mutations into to T/C.

It is a wrapper on bedtools(https://github.com/arq5x/bedtools2/releases).

Usage

maf2spec(
  bedtools_path = "bedtools",
  maf,
  ref_genome,
  context_length = 1,
  output_file
)

Arguments

bedtools_path

Path of bedtool executable, e.g. "~/bedtools/bin/bedtool"

maf

A maf file

ref_genome

An fa file path of reference genome sequence

context_length

The length of extension of each side of the mutation. By default it is 3 (trinucleotide context).

output_file

An output file that contains the context matrix

Value

Returns a matrix of mutation counts in different context, in each of the samples


gersteinlab/siglasso documentation built on Sept. 5, 2022, 8:45 p.m.