extract_run: Extract Digital PCR Run

Description Usage Arguments Details Value Note Author(s) See Also Examples

Description

Extract runs from a codedpcr object while preserving all other attributes.

Usage

1
extract_run(input, id)

Arguments

input

object of the class adpcr or dpcr.

id

vector of indices or names of runs.

Details

The extract_run function allows to choose one or more panels from an object of the adpcr or dpcr class and save it without changing other attributes. It is the most recommended method of extracting a subset from an array of panels, because it preserves class and structure of the object in contrary to standard operator Extract.

Value

The object of the input's class (adpcr or dpcr).

Note

The standard Extract operator x[i] treats dpcr objects as matrix and extracts values without preserving other attributies of the object.

Author(s)

Michal Burdukiewicz.

See Also

Opposite function: bind_dpcr Extract multiple runs belonging to an experiment of assay: extract_dpcr

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
#sample extracting
panels <- sim_adpcr(10, 40, 1000, pos_sums = FALSE, n_panels = 50)
single_panel <- extract_run(panels, 5)
random_three <- extract_run(panels, sample.int(ncol(panels), 3))
all_but_one <- extract_run(panels, -5)

#the same for fluorescence data
fluos <- sim_dpcr(10, 40, 1000, pos_sums = FALSE, n_exp = 50, 
                   fluo = list(0.1, 0))
single_fluo <- extract_run(fluos, 5)

dpcR documentation built on May 2, 2019, 7:04 a.m.