componentsTPs-class: Components based on parent and transformation product (TP)...

componentsTPs-classR Documentation

Components based on parent and transformation product (TP) linkage.

Description

This class is derived from components and is used to store components that result from linking feature groups that are (predicted to be) parents with feature groups that (are predicted to be) transformation products. For more details, see generateComponentsTPs.

Usage

## S4 method for signature 'componentsTPs'
as.data.table(x)

## S4 method for signature 'componentsTPs'
filter(
  obj,
  ...,
  retDirMatch = FALSE,
  minSpecSim = NULL,
  minSpecSimPrec = NULL,
  minSpecSimBoth = NULL,
  minFragMatches = NULL,
  minNLMatches = NULL,
  formulas = NULL,
  verbose = TRUE,
  negate = FALSE
)

## S4 method for signature 'componentsTPs'
plotGraph(obj, onlyLinked = TRUE, width = NULL, height = NULL)

Arguments

x, obj

A componentsTPs object.

..., verbose

Further arguments passed to the base filter method.

retDirMatch

If set to TRUE, only keep TPs for which the retention time direction (retDir, see Details in componentsTPs) matches with the observed direction. TPs will never be removed if the expected/observed direction is ‘⁠0⁠’ (i.e. unknown or not significantly different than the parent).

minSpecSim, minSpecSimPrec, minSpecSimBoth

The minimum spectral similarity of a TP compared to its parent (‘⁠0-1⁠’). The minSpecSimPrec and minSpecSimBoth apply to binned data that is shifted with the "precursor" and "both" method, respectively (see MS spectral similarity parameters for more details). Set to NULL to ignore.

minFragMatches, minNLMatches

Minimum number of parent/TP fragment and neutral loss matches, respectively. Set to NULL to ignore. See the ⁠Linking parents and transformation products⁠ section in generateComponentsTPs for more details.

formulas

A formulas object. The formula annotation data in this object is to verify if elemental additions/subtractions from metabolic logic reactions are possible (hence, it only works with data from generateTPsLogic). To verify elemental additions, only TPs with at least one candidate formula that has these elements are kept. Similarly, for elemental subtractions, any of the parent candidate formulae must contain the subtraction elements. Note that TPs are currently not filtered if either the parent or the TP has no formula annotations. Set to NULL to ignore.

negate

If TRUE then filters are applied in opposite manner.

onlyLinked

If TRUE then only components with links are plotted.

width, height

Passed to visNetwork.

Value

filter returns a filtered componentsTPs object.

plotGraph returns the result of visNetwork.

Methods (by generic)

  • as.data.table(componentsTPs): Returns all component data as a data.table.

  • filter(componentsTPs): Provides various rule based filtering options to clean and prioritize TP data.

  • plotGraph(componentsTPs): Plots an interactive network graph for linked components. Components are linked with each other if one or more transformation products overlap. The graph is constructed with the igraph package and rendered with visNetwork.

Slots

fromTPs

A logical that is TRUE when the componentization was performed with transformationProducts data.

S4 class hierarchy

  • components

    • componentsTPs

Note

The intensity values for components (used by plotSpectrum) are set to a dummy value (1) as no single intensity value exists for this kind of components.

References

\addCitations

igraph2

See Also

components for other relevant methods and generateComponents


rickhelmus/patRoon documentation built on April 25, 2024, 8:15 a.m.