numDroplets {twoddpcr}R Documentation

Retrieve the number of droplets.

Description

Retrieves the number of droplets in a ddpcrWell or ddpcrPlate object.

Usage

numDroplets(theObject, ...)

## S4 method for signature 'ddpcrWell'
numDroplets(theObject)

## S4 method for signature 'ddpcrPlate'
numDroplets(theObject)

Arguments

theObject

A ddpcrPlate object.

...

Other parameters depending on the type of theObject.

Value

For ddpcrWell objects, return the number of droplets as an integer.

For ddpcrPlate objects, return a named vector. The names correspond to a well name and each item corresponding to the number of droplets in that well.

Author(s)

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

Examples

## Count the number of droplets in a well.
aWell <- ddpcrWell(well=KRASdata[["E03"]])
numDroplets(aWell)

## Get all of the wells in a named vector.
krasPlate <- ddpcrPlate(wells=KRASdata)
(numberDroplets <- numDroplets(krasPlate))
sum(numberDroplets)

## We can choose to get a subset of the wells.
(numberDroplets <- numDroplets(krasPlate[c("H03", "A04")]))
sum(numberDroplets)


[Package twoddpcr version 1.16.0 Index]