NormalizeTPM: TPM normalization

Description Usage Arguments Details Value Examples

View source: R/Normalize.R

Description

NormalizeTPM performs TPM normalization, with possibility to log the result

Usage

1
2
NormalizeTPM(data, sce = NULL, tr_length = NULL, log = FALSE,
scale = 1, pseudo.count = 1)

Arguments

data

matrix; raw data (genes as rows and samples as columns)

sce

SingleCellExperiment; raw data

tr_length

data.frame with at least 2 columns: 'hgnc_symbol' and 'transcript_length'

log

logical; log TPMs?

scale

integer; scale factor to divide TPMs by

pseudo.count

numeric; if log = T, value to add to TPMs in order to avoid taking log(0)

Details

Gene length is estimated as the median of the lengths of all transcripts for each gene, as obtained from biomaRt. Genes for which length information cannot be found in biomaRt are dropped.

Value

matrix; normalized data (for transcript length and library size)

Examples

1
demo <- NormalizeTPM(ADImpute::demo_data)

ADImpute documentation built on Nov. 8, 2020, 5:30 p.m.