preTreatModes: Pre-treatment of multiple ionisation modes

Description Usage Arguments Value Examples

Description

Pre-treat both positive and negative ionisation modes for Binalysis and MetaboProfile classes.

Usage

1
2
3
4
5
6
7
preTreatModes(processed_data, parameters, verbose = TRUE)

## S4 method for signature 'Binalysis'
preTreatModes(processed_data, parameters, verbose = TRUE)

## S4 method for signature 'MetaboProfile'
preTreatModes(processed_data, parameters, verbose = TRUE)

Arguments

processed_data

S4 object of class Binalysis or MetaboProfile

parameters

object of class AnalysisParameters containing pre-treatment parameters

verbose

console output

Value

S4 object of class Analysis

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
library(metabolyseR)

## Retrieve file paths and sample information for example data
files <- metaboData::filePaths('FIE-HRMS','BdistachyonEcotypes')[1:2]

info <- metaboData::runinfo('FIE-HRMS','BdistachyonEcotypes')[1:2,]

## Detect spectral binning parameters
bp <- binneR::detectParameters(files)

## Perform spectral binning
analysis <- binneR::binneRlyse(files, 
                               info, 
                               parameters = bp)

## Declare pre-treatment parameters
pre_treatment_parameters <- analysisParameters('pre-treatment')
parameters(pre_treatment_parameters,
                        'pre-treatment') <- preTreatmentParameters(
 list(
   occupancyFilter = 'maximum',
   impute = 'all',
   transform = 'TICnorm'
 )
)
changeParameter(pre_treatment_parameters,'parallel') <- 'no'

## Perform pre-treatment
pre_treated_data <- preTreatModes(analysis,
                                  pre_treatment_parameters)

jasenfinch/metaboMisc documentation built on Feb. 10, 2022, 4:22 p.m.