sampleMSnSet {pRoloc} | R Documentation |
MSnSet
This function extracts a stratified sample of an MSnSet
.
sampleMSnSet(object, fcol = "markers", size = 0.2, seed)
object |
An instance of class |
fcol |
The feature meta-data column name containing the
marker (vector or matrix) definitions on which the MSnSet will be
stratified. Default is |
size |
The size of the stratified sample to be extracted. Default is 0.2 (20 percent). |
seed |
The optional random number generator seed. |
A stratified sample (according to the defined fcol
)
which is an instance of class "MSnSet"
.
Lisa Breckels
testMSnSet
unknownMSnSet
markerMSnSet
. See markers
for details
about markers encoding.
library(pRolocdata) data(tan2009r1) dim(tan2009r1) smp <- sampleMSnSet(tan2009r1, fcol = "markers") dim(smp) getMarkers(tan2009r1) getMarkers(smp)