tpm.direct: Function tpm.direct

Description Usage Arguments Details Value Author(s) Examples

Description

Takes a counts and genelength as input and converts to tpm units using the equation from [Harold Pimental](https://haroldpimentel.wordpress.com/2014/05/08/what-the-fpkm-a-review-rna-seq-expression-units/).

Usage

1
tpm.direct(counts, genelength, collapse = FALSE)

Arguments

counts

A numeric matrix of N genes x M Samples. All columns must be numeric.

collapse

T/F determines whether to use rowMeans on the genelength matrix [Default = FALSE]

geneLength

A vector or matrix of gene lengths.

Details

The result should be the same as using convertCounts with normalize='tpm' and log=FALSE

Genelength can be a vector (length == nrow(counts) or a matrix (same dim as counts). The genelength is used as is, or optionally collapsed to a vector by rowMeans.

Value

A matrix of TPM values

Author(s)

John Thompson, jrt@thompsonclan.org

Examples

1
myTPM <- tpm.classic(mycounts, mygenelength)

jrthompson54/DGE.Tools2 documentation built on May 12, 2021, 8:47 p.m.