20#ifndef _OVERLAPDEMULTIPLEXER_HPP
21#define _OVERLAPDEMULTIPLEXER_HPP
65 const std::vector<size_t>& muxIndices,
68 void GetMatrixBlockIndices(
size_t indexToDemux, std::vector<size_t>& muxIndices,
double demuxBlockExtra)
const override;
82 Eigen::Ref<Eigen::MatrixXd, 0, Eigen::Stride<Eigen::Dynamic, Eigen::Dynamic> > interpolatedIntensities,
83 double timeToInterpolate,
84 Eigen::Ref<const Eigen::MatrixXd> intensities,
85 Eigen::Ref<const Eigen::VectorXd> scanTimes);
94 static double InterpolateMatrix(
double pointToInterpolate, Eigen::Ref<const Eigen::VectorXd> points, Eigen::Ref<const Eigen::VectorXd> values);
Helper functions for demultiplexing Helper functions include nice methods of accessing CV parameters ...
Interface for calculating demultiplexing scheme.
boost::shared_ptr< const IPrecursorMaskCodec > const_ptr
Constant shared pointer definition.
Implementation of the IDemultiplexer interface that is able to handle overlap experiments.
static void InterpolateMuxRegion(Eigen::Ref< Eigen::MatrixXd, 0, Eigen::Stride< Eigen::Dynamic, Eigen::Dynamic > > interpolatedIntensities, double timeToInterpolate, Eigen::Ref< const Eigen::MatrixXd > intensities, Eigen::Ref< const Eigen::VectorXd > scanTimes)
Performs interpolation on a matrix of intensities using a vector of scanTimes and outputs them to a r...
msdata::SpectrumList_const_ptr sl_
A SpectrumList that provides access to the spectra specified in the muxIndices list provided to Build...
virtual ~OverlapDemultiplexer()
size_t cyclesInBlock_
The number of spectra with identical isolation parameters to use for interpolation.
Params params_
A set of user-defined options.
std::vector< size_t > spectrumIndices_
A cache of the indices provided by SpectrumIndices()
void BuildDeconvBlock(size_t index, const std::vector< size_t > &muxIndices, DemuxTypes::MatrixPtr &masks, DemuxTypes::MatrixPtr &signal) override
Translates a spectrum into a set of matrices to be solved by NNLS.
OverlapDemultiplexer(Params p=Params())
Constructs an OverlapDemultiplexer with optional user-specified parameters.
const std::vector< size_t > & SpectrumIndices() const override
Returns the indices to the demultiplexed windows in the solution matrix corresponding to the windows ...
IPrecursorMaskCodec::const_ptr pmc_
An IPrecursorMaskCodec that provides information about the experiment's scheme and can generate the m...
void Initialize(msdata::SpectrumList_const_ptr sl, IPrecursorMaskCodec::const_ptr pmc) override
Initializes the demultiplexer using the demux scheme provided by an IPrecursorMaskCodec.
size_t overlapRegionsInApprox_
The number of mux spectra nearby the spectrum to demux (in both retention time and m/z space) to use ...
void GetMatrixBlockIndices(size_t indexToDemux, std::vector< size_t > &muxIndices, double demuxBlockExtra) const override
Figures out which spectra to include in the system of equations to demux.
static double InterpolateMatrix(double pointToInterpolate, Eigen::Ref< const Eigen::VectorXd > points, Eigen::Ref< const Eigen::VectorXd > values)
Takes two vectors of equal length and solves an interpolation for the given point.
boost::shared_ptr< MatrixType > MatrixPtr
boost::shared_ptr< const msdata::SpectrumList > SpectrumList_const_ptr
User-defined options for demultiplexing.
bool applyWeighting
Weight the spectra nearby to the input spectrum more heavily in the solve than the outer ones.
pwiz::chemistry::MZTolerance massError
Mass error for extracting MS/MS peaks.
bool variableFill
Set to true if fill times are allowed to vary for each scan window.
struct for expressing m/z tolerance in either amu or ppm