The function subsetML enables direct subsetting of
data objects with MarkerList objects, as
long as they have a suitable featureNames,
rownames or names method, as
well as a subset method [. It is used for defining
'[' methods for NMF-class and
ExpressionMix-class.
subsetML(x, i, j, ..., drop = FALSE)
'[' of x.numeric or character
vectors or empty (missing) or NULL. Numeric
values are coerced to integer as by
as.integer (and hence truncated towards
zero). Character vectors will be matched to the
names of the object (or for
matrices/arrays, the dimnames): see
Character indices below for further details.
For [-indexing only: i, j,
... can be logical vectors, indicating
elements/slices to select. Such vectors are recycled if
necessary to match the corresponding extent. i,
j, ... can also be negative integers,
indicating elements/slices to leave out of the selection.
When indexing arrays by [ a single argument
i can be a matrix with as many columns as there
are dimensions of x; the result is then a vector
with elements corresponding to the sets of indices in
each row of i.
An index value of NULL is treated as if it were
integer(0). numeric or character
vectors or empty (missing) or NULL. Numeric
values are coerced to integer as by
as.integer (and hence truncated towards
zero). Character vectors will be matched to the
names of the object (or for
matrices/arrays, the dimnames): see
Character indices below for further details.
For [-indexing only: i, j,
... can be logical vectors, indicating
elements/slices to select. Such vectors are recycled if
necessary to match the corresponding extent. i,
j, ... can also be negative integers,
indicating elements/slices to leave out of the selection.
When indexing arrays by [ a single argument
i can be a matrix with as many columns as there
are dimensions of x; the result is then a vector
with elements corresponding to the sets of indices in
each row of i.
An index value of NULL is treated as if it were
integer(0). numeric or character
vectors or empty (missing) or NULL. Numeric
values are coerced to integer as by
as.integer (and hence truncated towards
zero). Character vectors will be matched to the
names of the object (or for
matrices/arrays, the dimnames): see
Character indices below for further details.
For [-indexing only: i, j,
... can be logical vectors, indicating
elements/slices to select. Such vectors are recycled if
necessary to match the corresponding extent. i,
j, ... can also be negative integers,
indicating elements/slices to leave out of the selection.
When indexing arrays by [ a single argument
i can be a matrix with as many columns as there
are dimensions of x; the result is then a vector
with elements corresponding to the sets of indices in
each row of i.
An index value of NULL is treated as if it were
integer(0).
data(sample.ExpressionSet)
e <- sample.ExpressionSet
annotation(e)
## [1] "hgu95av2"