spectraCount {RMassBank} | R Documentation

## Count MS2 spectra per compound

### Description

Counts the number of acquired spectra for a compound or multiple compounds

### Usage

    spectraCount(s)

    ## S4 method for signature 'RmbSpectraSet'
    spectraCount(s)

    ## S4 method for signature 'RmbSpectraSetList'
    spectraCount(s)

    ## S4 method for signature 'msmsWorkspace'
    spectraCount(s)

### Arguments

`s` | The object (`RmbSpectraSet`, `RmbSpectraSetList` or `msmsWorkspace`) to count the spectra in.

### Value

For `RmbSpectraSet` objects, a single number counting the spectra in that object. For `RmbSpectraSetList` or `msmsWorkspace`, a vector with spectra counts for all compounds (`RmbSpectraSet`s) in the object.

### Methods (by class)

- `RmbSpectraSet`: Counts the number of acquired spectra for an RmbSpectraSet

- `RmbSpectraSetList`: Counts the number of acquired spectra for an RmbSpectraSetList

- `msmsWorkspace`: Counts the number of acquired spectra for an msmsWorkSpace

### Author(s)

stravsmi

[Package RMassBank version 2.15.3 Index]