RankView: Rank plot

View source: R/RankView.R

RankViewR Documentation

Rank plot

Description

Draw the score and rank of genes on a scatter plot.

Usage

RankView(
  rankdata,
  genelist = NULL,
  decreasing = TRUE,
  top = 5,
  bottom = 5,
  cutoff = 2,
  main = NULL,
  filename = NULL,
  width = 5,
  height = 4,
  ...
)

Arguments

rankdata

A numeric vector, with gene as names.

genelist

A character vector, specifying genes to be labeled.

decreasing

Boolean, specifying the order of genes to plot.

top

Integer, specifying number of positive genes to be labeled.

bottom

Integer, specifying number of negative genes to be labeled.

cutoff

One numeric value indicating the fold of standard deviation used as cutoff; two number vector, such as c(-1, 1), specifying the exact cutoff for selecting top genes.

main

A character, specifying title.

filename

A character, specifying a file name to create on disk. Set filename to be "NULL", if don't want to save the figure.

width

Numeric, specifying width of figure.

height

Numeric, specifying height of figure.

...

Other available parameters in the function 'geom_text_repel'.

Value

An object created by ggplot, which can be assigned and further customized.

Author(s)

Wubing Zhang

Examples

file1 = file.path(system.file("extdata", package = "MAGeCKFlute"),
"testdata/rra.gene_summary.txt")
gdata = ReadRRA(file1)
rankdata = gdata$Score
names(rankdata) = gdata$id
RankView(rankdata)


WubingZhang/MAGeCKFlute documentation built on Jan. 27, 2024, 2:43 p.m.