I have an ExpressionSet object with 100 samples:
> length(sampleNames(eset1))
100
I also have a vector of the names of 75 samples (not the data itself):
> length(vecOf75)
75
How can I subset eset1
(and save it) according to the 75 sample names? That is, I want to disregard those samples in eset1
whose names are not listed in vecOf75
. Bear in mind that some of the samples corresponding to the 75 sample names may not be in eset1
. Thus,
> length(sampleNames(eset1))
should now give something <75.