getSamples {HELP} | R Documentation |
Fetch a subset of samples from a given data structure
getSamples(x, y, ...)
x |
the matrix of sample data to subset. If x is a vector it is interpreted as a matrix. x can also be of class "ExpressionSet" . |
y |
which sample(s) to use as data. Can be a vector of characters matching sample names, integers indicating which samples to choose, or a mixture of the two. If not supplied, all samples will be used. |
... |
Arguments to be passed to methods (see getSamples-methods ):
element AssayData to use for a given ExpressionSet input (default is "exprs") order ... |
Returns a matrix of values corresponding to a subset of samples from the data supplied, where columns correspond to samples. Function halts if no samples to return.
Reid F. Thompson (rthompso@aecom.yu.edu)
data(sample.ExpressionSet) se.ABC <- getSamples(sample.ExpressionSet, c("A", "B", "C"), element="se.exprs") se.ABC[1:10,]