flat_pattern_filter: Flat pattern filter

Description Usage Arguments Value Examples

Description

Performs a flat pattern filter over the dataset.

Usage

1
2
flat_pattern_filter(dataset, filter.function = "iqr", 
by.percent = TRUE, by.threshold = FALSE, red.value = 0)

Arguments

dataset

list representing the dataset from a metabolomics experiment.

filter.function

filter function. It can be:

  • "iqr" - Interquantile Range

  • "rsd" - Relative Standard Deviation

  • "sd" - Standard Deviation

  • "mad" - Median Absolute Deviation

  • "mean" - Mean

  • "median" - Median

by.percent

boolean value, if TRUE the number of variables to filter will be a percentage of the number of variables in the dataset; percentage is given by the "red.value" parameter

by.threshold

boolean value, if TRUE, defines filtering will select variables where values of filtering function are below a given threshold. Threshold is defined by red.value that defines the minimum value of the function needed to keep the variable.

red.value

it can be the percentage or the threshold number. If red.value = "auto", will calculate number of variables to remove automatically

Value

Returns the dataset with the data filtered.

Examples

1
2
3
4
5
  ## Example of flat pattern filter
  library(specmine.datasets)
  data(propolis)
  dataset.filtered = flat_pattern_filter(propolis, "iqr", by.percent = TRUE, 
		     red.value = 20)

specmine documentation built on Sept. 21, 2021, 5:06 p.m.