Learn R Programming

RaceID (version 0.3.9)

plotdiffgenesnb: Function for plotting differentially expressed genes

Description

This is a plotting function for visualizing the output of the diffexpnb or clustdiffgenes function as MA plot.

Usage

plotdiffgenesnb(
  x,
  pthr = 0.05,
  padj = TRUE,
  lthr = 0,
  mthr = -Inf,
  Aname = NULL,
  Bname = NULL,
  show_names = TRUE,
  ...
)

Value

None

Arguments

x

output of the function diffexpnb.

pthr

real number between 0 and 1. This number represents the p-value cutoff applied for displaying differentially expressed genes. Default value is 0.05. The parameter padj (see below) determines if this cutoff is applied to the uncorrected p-value or to the Benjamini-Hochberg corrected false discovery rate.

padj

logical value. If TRUE, then genes with a Benjamini-Hochberg corrected false discovery rate lower than pthr are displayed. If FALSE, then genes with a p-value lower than pthr are displayed.

lthr

real number between 0 and Inf. Differentially expressed genes are displayed only for log2 fold-changes greater than lthr. Default value is 0.

mthr

real number between -Inf and Inf. Differentially expressed genes are displayed only for log2 mean expression greater than mthr. Default value is -Inf.

Aname

name of expression set A, which was used as input to diffexpnb. If provided, this name is used in the axis labels. Default value is NULL.

Bname

name of expression set B, which was used as input to diffexpnb. If provided, this name is used in the axis labels. Default value is NULL.

show_names

logical value. If TRUE then gene names displayed for differentially expressed genes. Default value is FALSE.

...

Additional arguments for function plot.

Examples

Run this code
sc <- SCseq(intestinalDataSmall)
sc <- filterdata(sc)
sc <- compdist(sc)
sc <- clustexp(sc)
sc <- findoutliers(sc)
A <- names(sc@cpart)[sc@cpart %in% c(1,2)]
B <- names(sc@cpart)[sc@cpart %in% c(3)]
y <- diffexpnb(getfdata(sc,n=c(A,B)), A=A, B=B )
plotdiffgenesnb(y)

Run the code above in your browser using DataLab