pub enum RefPeakDataLevel<'a, C, D>where
C: CentroidLike,
D: DeconvolutedCentroidLike,{
Missing,
RawData(&'a BinaryArrayMap),
Centroid(&'a PeakSetVec<C, MZ>),
Deconvoluted(&'a PeakSetVec<D, Mass>),
}
Expand description
An variant for dispatching to different strategies of computing common statistics of different levels of peak data.
Variants§
Missing
RawData(&'a BinaryArrayMap)
Centroid(&'a PeakSetVec<C, MZ>)
Deconvoluted(&'a PeakSetVec<D, Mass>)
Implementations§
Source§impl<C, D> RefPeakDataLevel<'_, C, D>where
C: CentroidLike,
D: DeconvolutedCentroidLike,
impl<C, D> RefPeakDataLevel<'_, C, D>where
C: CentroidLike,
D: DeconvolutedCentroidLike,
Sourcepub fn base_peak(&self) -> CentroidPeak
pub fn base_peak(&self) -> CentroidPeak
Compute the base peak of a spectrum
pub fn search(&self, query: f64, error_tolerance: Tolerance) -> Option<usize>
Sourcepub fn len(&self) -> usize
pub fn len(&self) -> usize
Find the number of points in a profile spectrum, or the number of peaks for a centroid spectrum
Sourcepub fn iter(&self) -> PeakDataIterDispatch<'_, C, D> ⓘ
pub fn iter(&self) -> PeakDataIterDispatch<'_, C, D> ⓘ
Iterate over MZPoint
data encoded in the peak data.
NOTE: Values are produced in the order they are stored, so the data are not guaranteed to be ordered by m/z.
Sourcepub fn get(&self, i: usize) -> Option<MZPoint>
pub fn get(&self, i: usize) -> Option<MZPoint>
Get the i
th point in the peak data.
NOTE: There is no guarantee that values are stored in m/z order.
Sourcepub fn fetch_summaries(&self) -> SpectrumSummary
pub fn fetch_summaries(&self) -> SpectrumSummary
Compute summary information about the peak data’s m/z range, base peak, total ion current, and number of data points
Source§impl<C, D> RefPeakDataLevel<'_, C, D>
impl<C, D> RefPeakDataLevel<'_, C, D>
pub fn cloned(&self) -> PeakDataLevel<C, D>
Trait Implementations§
Auto Trait Implementations§
impl<'a, C, D> Freeze for RefPeakDataLevel<'a, C, D>
impl<'a, C, D> RefUnwindSafe for RefPeakDataLevel<'a, C, D>where
C: RefUnwindSafe,
D: RefUnwindSafe,
impl<'a, C, D> Send for RefPeakDataLevel<'a, C, D>
impl<'a, C, D> Sync for RefPeakDataLevel<'a, C, D>
impl<'a, C, D> Unpin for RefPeakDataLevel<'a, C, D>
impl<'a, C, D> UnwindSafe for RefPeakDataLevel<'a, C, D>where
C: RefUnwindSafe,
D: RefUnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more