normalizeTEbyLoess: Normalize the TE by Loess

View source: R/normalizeTEbyLoess.R

normalizeTEbyLoessR Documentation

Normalize the TE by Loess

Description

Fitting the translational efficiency values with the mRNA value by loess.

Usage

normalizeTEbyLoess(
  TE,
  log2 = TRUE,
  pseudocount = 0.001,
  span = 2/3,
  family.loess = "symmetric"
)

Arguments

TE

output of translationalEfficiency.

log2

logical(1L). Do log2 transform for TE or not. If TE value is not log2 transformed, please set it as TRUE.

pseudocount

The number will be add to sum of reads count to avoid X/0.

span, family.loess

Parameters will be passed to loess

Value

A list with RPFs, mRNA levels and TE as a matrix with log2 transformed translational efficiency.

Examples

path <- system.file("extdata", package="ribosomeProfilingQC")
cnts <- readRDS(file.path(path, "cnts.rds"))
fpkm <- getFPKM(cnts)
te <- translationalEfficiency(fpkm)
te1 <- normalizeTEbyLoess(te)
plotTE(te)
plotTE(te1, log2=FALSE)

jianhong/ribosomeProfilingQC documentation built on April 15, 2024, 7:10 p.m.