subBoxplot: boxplot with data points

Description Usage Arguments Value Note Examples

View source: R/subBoxplot.R

Description

Boxplot with data points and labeled outliers.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
subBoxplot(
  y,
  x,
  labels = NULL,
  keepN = TRUE,
  classCol = getOption("subClassCol"),
  points = FALSE,
  width = 20,
  showOutliers = FALSE,
  ...
)

Arguments

y

a numeric vector.

x

a factor, length(x)==length(y).

labels

a character vector, if NULL, names(y) is used.

keepN

logical or numeric indicating which samples to include.

classCol

a character vector specifying class colors.

points

logical indicating whether points are to be added to boxes.

width

numeric to adjust point stacking - increase to reduce width.

showOutliers

logical indicating whether outliers are highlighted.

...

additional arguments to be passed to graphics::boxplot.

Value

a boxplot

Note

For data points, y-values are grouped and averaged - not exact!

Examples

1
2
3
4
5
6
isCMS4 <- rownames(crcTCGAsubset) %in%
    templates.CMS$probe[templates.CMS$class == 'CMS4']
y <- colSums(Biobase::exprs(crcTCGAsubset)[isCMS4,])
x <- crcTCGAsubset$CMS
subBoxplot(y, x, ylab = expression(sum(log2(RSEM))), main = 'CMS4 genes',
     keepN = which(x != "CMS1"), notch = TRUE)

peterawe/CMScaller documentation built on June 13, 2020, 4:49 a.m.