prepare_plot_data: Format 'scMethrix' matrix to long form data for plotting

Description Usage Arguments Value

View source: R/scMethrix_plot.R

Description

Format scMethrix matrix to long form data for plotting

Usage

1
2
3
4
5
6
7
8
9
prepare_plot_data(
  scm = NULL,
  assay = "score",
  regions = NULL,
  n_cpgs = 25000,
  pheno = NULL,
  verbose = TRUE,
  na.rm = T
)

Arguments

scm

scMethrix; the single cell methylation experiment

assay

string; name of an existing assay. Default = "score"

regions

Granges; genomic regions to be summarized. Could be a data.table with 3 columns (chr, start, end) or a GenomicRanges object

n_cpgs

integer; Use these many random CpGs for plotting. Default 25000. Set it to NULL to use all - which can be memory expensive. The seed will be set to n_cpgs for consistency.

pheno

string; Col name of colData(m). Will be used as a factor to color different groups

verbose

boolean; Flag for outputting function status messages. Default = TRUE

na.rm

boolean; remove NA values from the output

Value

'Long' matrix for methylation


CompEpigen/scMethrix documentation built on Nov. 6, 2021, 3:09 p.m.