zFPKMPlot: zFPKM Transformation

View source: R/zfpkm.R

zFPKMPlotR Documentation

zFPKM Transformation

Description

Perform the zFPKM transform on RNA-seq FPKM data. This algorithm is based on the publication by Hart et al., 2013 (Pubmed ID 24215113). Reference recommends using zFPKM > -3 to select expressed genes. Validated with encode open/closed promoter chromatin structure epigenetic data on six of the ENCODE cell lines. Works well for gene level data using FPKM or TPM. Does not appear to calibrate well for transcript level data.

Usage

zFPKMPlot(
  fpkmDF,
  assayName = "fpkm",
  FacetTitles = FALSE,
  PlotXfloor = -20,
  peak_parameters = list(0.02, 1)
)

Arguments

fpkmDF

A SummarizedExperiment or data frame containing raw FPKM (or TPM) values. Each row corresponds to a gene/transcript and each column corresponds to a sample. NOTE: these are NOT log_2 transformed. Also, the rownames are gene/transcript names and NOT included as a separate column

assayName

When input is a SummarizedExperiment, names the specific assay. Typically one of "fpkm" or "tpm" [default = "fpkm"]

FacetTitles

use to label each facet with the sample name [default = FALSE]

PlotXfloor

Lower limit for X axis (log2FPKM units) [default = -20] set to NULL to disable

peak_parameters

A list containing two values for identifying peaks in the density plot: minpeakheight and minpeakdistance (from pracma::findpeaks). Default is peak_parameters = list(minpeakheight = 0.02, minpeakdistance = 1)

  • minpeakheight: the minimum (absolute) height a peak has to have to be recognized as such. Default is 0.02.

  • minpeakdistance: the minimum distance (in indices) peaks have to have to be counted. Default is 1.

Value

Displays plots of zFPKM distributions

Author(s)

Ron Ammar, ron.ammar@bms.com

References

http://www.ncbi.nlm.nih.gov/pubmed/24215113

Examples

library(dplyr)
gse94802 <- "ftp://ftp.ncbi.nlm.nih.gov/geo/series/GSE94nnn/GSE94802/suppl/GSE94802_Minkina_etal_normalized_FPKM.csv.gz"
temp <- tempfile()
download.file(gse94802, temp)
fpkm <- read.csv(gzfile(temp), row.names=1)
MyFPKMdf <- select(fpkm, -MGI_Symbol)

zFPKMPlot(MyFPKMdf)

# using different parameters to identify peaks
zFPKMPlot(MyFPKMdf, peak_parameters = list(0.01, 1))


ronammar/zFPKM documentation built on Aug. 10, 2024, 2:14 p.m.