plotBubble: Basic plot of binned vectors.

Description Usage Arguments Value See Also Examples

View source: R/plotBubble.R

Description

This function plots takes two vectors, calculates the contingency table and plots circles sized by the contingency table value. Optional significance vectors of the values significant will shade the circles by proportion of significance.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
plotBubble(
  yvector,
  xvector,
  sigvector = NULL,
  nbreaks = 10,
  ybreak = quantile(yvector, p = seq(0, 1, length.out = nbreaks)),
  xbreak = quantile(xvector, p = seq(0, 1, length.out = nbreaks)),
  scale = 1,
  local = FALSE,
  ...
)

Arguments

yvector

A vector of values represented along y-axis.

xvector

A vector of values represented along x-axis.

sigvector

A vector of the names of significant features (names should match x/yvector).

nbreaks

Number of bins to break yvector and xvector into.

ybreak

The values to break the yvector at.

xbreak

The values to break the xvector at.

scale

Scaling of circle bin sizes.

local

Boolean to shade by signficant bin numbers (TRUE) or overall proportion (FALSE).

...

Additional plot arguments.

Value

A matrix of features along rows, and the group membership along columns.

See Also

plotMRheatmap

Examples

1
2
3
4
5
6
7
8
9
data(mouseData)
mouseData = mouseData[which(rowSums(mouseData)>139),]
sparsity = rowMeans(MRcounts(mouseData)==0)
lor = log(fitPA(mouseData,cl=pData(mouseData)[,3])$oddsRatio)
plotBubble(lor,sparsity,main="lor ~ sparsity")
# Example 2
x = runif(100000)
y = runif(100000)
plotBubble(y,x)

metagenomeSeq documentation built on Nov. 8, 2020, 5:34 p.m.