select.samples.Rd
This function select samples based on information given in the metadata
select.samples(siamcat, filter, allowed.set = NULL,
allowed.range = NULL, verbose = 1)
an object of class siamcat-class
string, name of the meta variable on which the selection should be done
a vector of allowed values
a range of allowed values
integer, control output: 0
for no output at all,
1
for only information about progress and success, 2
for
normal level of information and 3
for full debug information,
defaults to 1
an object of class siamcat-class with labels and metadata filtered in order to contain only allowed values
This functions selects labels and metadata based on a specific column in the metadata. Provided with a column-name in the metadata and a range or a set of allowed values, the function will filter the siamcat-class object accordingly.
data(siamcat_example)
# Select all samples that fall into an Age-range between 25 and 80 years
siamcat_selected <- select.samples(siamcat_example,
filter='Age',
allowed.range=c(25, 80))
#> Warning: The machine learning pipeline has to be run again after filtering the samples
#> Warning: Selcting samples may affect the results of feature filtering and normalization
#> For sanity, results from previous analyses (e.g. filtered features) will be removed!
#> Selecting samples finished
# Select only female samples
siamcat_female <- select.samples(siamcat_example,
filter='Gender',
allowed.set=c('F'))
#> Warning: The machine learning pipeline has to be run again after filtering the samples
#> Warning: Selcting samples may affect the results of feature filtering and normalization
#> For sanity, results from previous analyses (e.g. filtered features) will be removed!
#> Selecting samples finished