ggplot.well: ggplot methods for the 'ddpcrWell' and 'ddpcrPlate' classes.

Description Usage Arguments Value Author(s) See Also Examples

Description

These functions work in the same way as the original ggplot method, but handles the coercion of the object into a data frame.

ggplot.well is a ggplot method for the ddpcrWell class.

ggplot.multiwell is a ggplot method for the ddpcrPlate class.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
ggplot.well(
  data,
  mapping = aes_string(x = "Ch2.Amplitude", y = "Ch1.Amplitude", colour = cMethod),
  cMethod = NULL,
  ...,
  environment = parent.frame()
)

## S4 method for signature 'ddpcrWell'
ggplot.well(
  data,
  mapping = aes_string(x = "Ch2.Amplitude", y = "Ch1.Amplitude", colour = cMethod),
  cMethod = "None",
  ...,
  environment = parent.frame()
)

ggplot.plate(
  data,
  mapping = aes_string(x = "Ch2.Amplitude", y = "Ch1.Amplitude", colour = class),
  cMethod = "None",
  ...,
  environment = parent.frame()
)

## S4 method for signature 'ddpcrPlate'
ggplot.plate(
  data,
  mapping = aes_string(x = "Ch2.Amplitude", y = "Ch1.Amplitude", colour = cMethod),
  cMethod = "None",
  ...,
  environment = parent.frame()
)

Arguments

data

A ddpcrWell or ddpcrPlate object.

mapping

A list of aesthetic mappings to use for the plot. Defaults to ggplot2::aes_string(x="Ch2.Amplitude", y="Ch1.Amplitude", colour=cMethod), where cMethod is taken from the parameter of the same name.

cMethod

The name or column number of the classification to use. This is renamed internally to "class" for use with mapping. Defaults to "None".

...

Other arguments passed onto ggplot.

environment

Where to look if a mapping variable is not defined. Defaults to parent.frame(), i.e. the environment in which ggplot.well() or ggplot.multiwell() is called.

Value

A ggplot object using the slots in the given object.

Author(s)

Anthony Chiu, anthony.chiu@cruk.manchester.ac.uk

See Also

dropletPlot builds upon these ggplot methods to plot droplet amplitude plots with a colour-blind friendly palette.

The original ggplot method in the ggplot2 package is used internally.

Examples

1
2
3
4
5
6
7
8
## Plot the droplets in one well.
library(ggplot2)
aWell <- ddpcrWell(KRASdata[["E03"]])
ggplot.well(aWell, cMethod="Cluster") + geom_point()

## Plot the droplets in all of the wells in a single plot.
krasPlate <- ddpcrPlate(KRASdata)
ggplot.plate(krasPlate, cMethod="Cluster") + geom_point()

twoddpcr documentation built on Nov. 8, 2020, 5:49 p.m.