pool_mut_mat: Pool multiple samples from a mutation matrix together

Description Usage Arguments Value Examples

View source: R/pool_mut_matrix.R

Description

The mutation counts of columns (samples) are added up according to the grouping variable.

Usage

1

Arguments

mut_matrix

Mutation count matrix (dimensions: x mutation types X n samples)

grouping

Grouping variable

Value

Mutation count matrix (dimensions: x mutation types X n groups)

Examples

1
2
3
4
5
6
## See the 'mut_matrix()' example for how we obtained the mutation matrix:
mut_mat <- readRDS(system.file("states/mut_mat_data.rds",
  package = "MutationalPatterns"
))
grouping <- c(rep("colon", 3), rep("intestine", 3), rep("liver", 3))
pool_mut_mat(mut_mat, grouping)

MutationalPatterns documentation built on Nov. 14, 2020, 2:03 a.m.