com.compomics.util.experiment.filters.massspectrometry.spectrumfilters
Class PeakFilter
java.lang.Object
com.compomics.util.experiment.filters.massspectrometry.SpectrumFilter
com.compomics.util.experiment.filters.massspectrometry.spectrumfilters.PeakFilter
- All Implemented Interfaces:
- java.io.Serializable
public class PeakFilter
- extends SpectrumFilter
A peak filter.
- Author:
- Marc Vaudel
- See Also:
- Serialized Form
Fields inherited from class com.compomics.util.experiment.filters.massspectrometry.SpectrumFilter |
name |
Constructor Summary |
PeakFilter(double mz,
double mzTolerance,
boolean isPpm,
double intensity,
double intensityTolerance)
Constructor. |
Method Summary |
java.lang.String |
getDescription()
Returns a description of the validated spectra, typically "containing a
peak at m/z 114". |
double |
getError(double otherMz)
Get the absolute matching error in Da. |
boolean |
validateSpectrum(MSnSpectrum spectrum)
Indicates whether a peak was found in the spectrum at the desired m/z in
the given intensity quartile. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PeakFilter
public PeakFilter(double mz,
double mzTolerance,
boolean isPpm,
double intensity,
double intensityTolerance)
- Constructor.
- Parameters:
mz
- the m/z to look formzTolerance
- the m/z toleranceisPpm
- a boolean indicating whether the m/z tolerance is in ppmintensity
- the intensity to look forintensityTolerance
- the intensity relative tolerance (0.1 for 10%)
validateSpectrum
public boolean validateSpectrum(MSnSpectrum spectrum)
- Indicates whether a peak was found in the spectrum at the desired m/z in
the given intensity quartile.
- Specified by:
validateSpectrum
in class SpectrumFilter
- Parameters:
spectrum
- the spectrum to inspect
- Returns:
- a boolean indicating whether a peak was found in the spectrum at
the desired m/z in the given intensity quartile
getError
public double getError(double otherMz)
- Get the absolute matching error in Da.
- Parameters:
otherMz
-
- Returns:
- the absolute matching error
getDescription
public java.lang.String getDescription()
- Description copied from class:
SpectrumFilter
- Returns a description of the validated spectra, typically "containing a
peak at m/z 114".
- Specified by:
getDescription
in class SpectrumFilter
- Returns:
- a description of the validated spectra
Copyright © 2013. All Rights Reserved.