removeCensored {prada}R Documentation

Remove rows that contain censored data

Description

Remove rows that contain censored data in the colums of x specified by columns.

Usage

## S4 method for signature 'matrix':
removeCensored(x, values, columns, na.rm=TRUE)
## S4 method for signature 'data.frame':
removeCensored(x, values, columns, na.rm=TRUE)
## S4 method for signature 'cytoFrame':
removeCensored(x, values, columns, na.rm=TRUE)

Arguments

x Object of class matrix, data.frame, or cytoFrame.
values Values that correspond to censored data. If missing, range(x) is used.
columns Numeric or character vector specifying the columns of x that are compared against values. If missing, 1:ncol(x) is used.
na.rm Logical. If TRUE, rows that contain NA values are also removed.

Details

The function removes all rows that contain, in the columns specified by the columns argument, values that are contained in the values argument. If na.rm is TRUE, then rows that contain NA values are also removed.

An application is with FACS data, where measurements outside of the detector's dynamic range produce minimal or maximal values. For example, if a 16-bit A/D converter was used, top-censored data would have a value of 65535.

Value

Object of the same class as x, with some rows removed.

Author(s)

Florian Hahne <f.hahne@dkfz.de>, Wolfgang Huber <huber@ebi.ac.uk>

Examples

set.seed(8215)
mat <- matrix(floor(runif(20000)*1024), ncol=4)
range(mat[,1])
mat <- removeCensored(mat, columns=1:2)
range(mat[,1])
range(mat[,3])

[Package prada version 1.18.0 Index]