Subset rows and columns in a multiData structure
The function restricts each data
component to the given columns and rows.
mtd.subset( # Input multiData, # Rows and columns to keep rowIndex = NULL, colIndex = NULL, invert = FALSE, # Strict or permissive checking of structure? permissive = FALSE, # Output formatting options drop = FALSE)
multiData |
A multiData structure. |
rowIndex |
A list in which each component corresponds to a set and is a vector giving the rows to be retained in that
set. All indexing methods recognized by R can be used (numeric,
logical, negative indexing, etc). If |
colIndex |
A vector giving the columns to be retained. All indexing methods recognized by R can be used (numeric,
logical, negative indexing, etc). In addition, column names of the retained columns may be given; if a given
name cannot be matched to a column, an error will be thrown. If |
invert |
Logical: should the selection be inverted? |
permissive |
Logical: should the function tolerate "loose" |
drop |
Logical: should dimensions with extent 1 be dropped? |
A multiData structure is intended to store (the same type of) data for multiple, possibly independent,
realizations
(for example, expression data for several independent experiments). It is a list where
each component corresponds to an (independent) data set. Each component is in turn a list that can hold
various types of information but must have a data
component. In a "strict" multiData structure, the
data
components are required to each be a matrix or a data frame and have the same number of
columns. In a "loose" multiData structure, the data
components can be anything (but for most
purposes should be of comparable type and content).
This function assumes a "strict" multiData structure unless permissive
is TRUE
.
A multiData structure containing the selected rows and columns. Attributes (except possibly dimensions and the corresponding dimnames) are retained.
Peter Langfelder
multiData
to create a multiData structure.
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.