insertBeadData: Add, modify or remove data in a beadLevelData object

Description Usage Arguments Details Value Author(s) Examples

View source: R/insertBeadData.R

Description

Add, modify or remove data in a beadLevelData object.

Usage

1
2
    insertBeadData(BLData, array = 1, what, data)
    removeBeadData(BLData, array = 1, what)

Arguments

BLData

An object of class beadLevelData-class.

array

Positive integer specifying what section should be modified.

what

Name of the data that is being modified. If ‘what’ doesn't exist then a new entry is created using the name specified in this argument.

data

A numeric vector to be stored, the same length as the number of beads in the section specified by the array argument.

Details

These functions allow the beadData slot of the beadLevelData-class object to be modified for a given array.

Value

Returns an object of class beadLevelData-class.

Author(s)

Mike Smith

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
      if(require(beadarrayExampleData)){

	data(exampleBLData)
	logIntensity <- log2(getBeadData(exampleBLData, what = "Grn", array = 1))

	## This will add a new entry called "LogGrn" to BLData
	exampleBLData <- insertBeadData(exampleBLData, array = 1, what = "LogGrn", data = logIntensity)
	head(exampleBLData[[1]])

	## Supplying an existing entry to "what" will overwrite the current data
    exampleBLData <- insertBeadData(exampleBLData, array = 1, what = "Grn", data = logIntensity)
	head(exampleBLData[[1]])

    }

beadarray documentation built on Nov. 8, 2020, 4:51 p.m.