Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

flatten

Flatten an mzID related class into a table


Description

This function flattens the content of the object into a table by merging the content intelligently (it knows the links between the different objects).

Usage

flatten(object, safeNames = TRUE)

## S4 method for signature 'mzIDpsm'
flatten(object, safeNames = TRUE)

## S4 method for signature 'mzIDpeptides'
flatten(object, safeNames = TRUE)

## S4 method for signature 'mzID'
flatten(object, safeNames = TRUE)

## S4 method for signature 'mzIDCollection'
flatten(object, safeNames = TRUE)

Arguments

object

The object to be flattened

safeNames

Logical. Should column names be lowered to ensure compitability between different versions of the mzIdentML schema. Defaults to TRUE

Value

A data.frame with the flattened result or a list of data.frames

Methods (by class)

  • mzIDpsm: Merge id and scans according to the mapping

  • mzIDpeptides: Merge peptides with their modifications

  • mzID: Flatten an mzID object with respect to psm'

  • mzIDCollection: Flatten all mzID object in the collection into a list of data frames.

See Also

Examples

exampleFile <- system.file('extdata', '55merge_tandem.mzid', package = 'mzID')
mzResults <- mzID(exampleFile)
head(flatten(mzResults))

mzID

An mzIdentML parser for R

v1.28.0
GPL (>= 2)
Authors
Laurent Gatto [ctb, cre] (<https://orcid.org/0000-0002-1520-2268>), Thomas Pedersen [aut] (<https://orcid.org/0000-0002-6977-7147>), Vladislav Petyuk [ctb]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.