sub-BAf-ANY-ANY-ANY-method: Extract a part of data

Description Usage Arguments Value Author(s) See Also Examples

Description

This function works in almost same way as the generic form of it.
Note: When j is missing, this takes rows instead of columns.

Usage

1
2
## S4 method for signature 'BAf,ANY,ANY,ANY'
x[i, j, ..., droplevel = TRUE, drop]

Arguments

x

an object of the BAf-class

i

row

j

column

..., drop

currently not used

droplevel

whether unused factor levels after extraction should be dropped out in @sinfo and @binder

Value

an object of the BAf-class that contains a part

Author(s)

Mun-Gwan Hong <mun-gwan.hong@scilifelab.se>

See Also

Extract

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
data(sba)
# the samples in 1:4 rows and the values of 3rd target
sba2 <- sba[1:4, 3]
summary(sba2)

# the data of "T2" and "T3"
sba3 <- sba[, c("T2", "T3")]
summary(sba3)

# the data of the samples on plate 2
sba4 <- sba[sba@sinfo$plate == "2", ]
summary(sba4)

# the data of cancer patients only
sba5 <- sba[!is.na(sba@sinfo$dis) & sba@sinfo$dis == "cancer", ]
summary(sba5)

Rundmus/BAf-R_package documentation built on May 18, 2020, 12:59 p.m.