51 template <
typename SpectrumType>
54 if (spectrum.size() <= peakcount_)
return;
60 std::vector<Size> indices;
61 for (
Size i = 0; i != peakcount_; ++i)
A base class for all classes handling default parameters.
Definition: DefaultParamHandler.h:66
In-Memory representation of a mass spectrometry run.
Definition: MSExperiment.h:45
The representation of a 1D spectrum.
Definition: MSSpectrum.h:44
MSSpectrum & select(const std::vector< Size > &indices)
void sortByIntensity(bool reverse=false)
Lexicographically sorts the peaks by their intensity.
NLargest removes all but the n largest peaks.
Definition: NLargest.h:30
void init_()
handles the initialization of the default parameters for the 2 constructors
NLargest & operator=(const NLargest &source)
assignment operator
NLargest(UInt n)
detailed constructor
NLargest()
default constructor
void filterPeakSpectrum(PeakSpectrum &spectrum)
~NLargest() override
destructor
void filterPeakMap(PeakMap &exp)
UInt peakcount_
Definition: NLargest.h:78
void updateMembers_() override
This method is used to update extra member variables at the end of the setParameters() method.
void filterSpectrum(SpectrumType &spectrum)
Definition: NLargest.h:52
NLargest(const NLargest &source)
copy constructor
unsigned int UInt
Unsigned integer type.
Definition: Types.h:64
size_t Size
Size type e.g. used as variable which can hold result of size()
Definition: Types.h:97
Main OpenMS namespace.
Definition: openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19