Implementation of the IDemultiplexer interface that is able to handle overlap experiments.
More...
#include <OverlapDemultiplexer.hpp>
|
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 row vector of interpolated intensities.
|
|
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.
|
|
Implementation of the IDemultiplexer interface that is able to handle overlap experiments.
Definition at line 30 of file OverlapDemultiplexer.hpp.
◆ OverlapDemultiplexer()
pwiz::analysis::OverlapDemultiplexer::OverlapDemultiplexer |
( |
Params |
p = Params() | ) |
|
|
explicit |
Constructs an OverlapDemultiplexer with optional user-specified parameters.
- Parameters
-
p | Options to use in demultiplexing (see Params for available options) |
◆ ~OverlapDemultiplexer()
virtual pwiz::analysis::OverlapDemultiplexer::~OverlapDemultiplexer |
( |
| ) |
|
|
virtual |
◆ Initialize()
◆ BuildDeconvBlock()
Translates a spectrum into a set of matrices to be solved by NNLS.
- Parameters
-
[in] | index | Index of the requested spectrum to be demultiplexed |
[in] | muxIndices | The indices to mulitplexed spectra to use for demultiplexing. These spectra should be near in time to the spectrum to demultiplex and there should be enough to provide a unique solution. |
[out] | masks | The design matrix with rows corresponding to individual spectra and columns corresponding to MS1 isolation windows |
[out] | signal | A transition (MS1 isolation -> MS2 point/centroid) to be deconvolved formatted as a column vector (or a set of transitions formatted as a matrix) |
Implements pwiz::analysis::IDemultiplexer.
◆ GetMatrixBlockIndices()
void pwiz::analysis::OverlapDemultiplexer::GetMatrixBlockIndices |
( |
size_t |
indexToDemux, |
|
|
std::vector< size_t > & |
muxIndices, |
|
|
double |
demuxBlockExtra |
|
) |
| const |
|
overridevirtual |
Figures out which spectra to include in the system of equations to demux.
This skips over MS1 spectra and returns the indices of a range of MS2 spectra that can be used to demultiplex the chosen spectrum. This handles the case where the chosen spectrum is at the beginning or end of a file and chooses a sufficient number of nearby MS2 spectra accordingly. More indices will be included if the user has chosen to add additional demux blocks.
- Postcondition
- The returned indices are sorted
- Parameters
-
[in] | indexToDemux | Index of the requested spectrum |
[out] | muxIndices | Indices of the multiplexed MS2 spectra to be used for demultiplexing |
[in] | demuxBlockExtra | Amount to pad the block size by |
Implements pwiz::analysis::IDemultiplexer.
◆ SpectrumIndices()
const std::vector< size_t > & pwiz::analysis::OverlapDemultiplexer::SpectrumIndices |
( |
| ) |
const |
|
overridevirtual |
Returns the indices to the demultiplexed windows in the solution matrix corresponding to the windows extracted from the spectrum whose index was provided to BuildDeconvBlock()
- Returns
- Returns the demux indices for the solved spectrum
Implements pwiz::analysis::IDemultiplexer.
◆ InterpolateMuxRegion()
static void pwiz::analysis::OverlapDemultiplexer::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 |
|
) |
| |
|
staticprotected |
Performs interpolation on a matrix of intensities using a vector of scanTimes and outputs them to a row vector of interpolated intensities.
- Parameters
-
[out] | interpolatedIntensities | The row vector of interpolated intensities mapped from timeToInterpolate. The Ref template convinces Eigen that this can be column or row. |
[in] | timeToInterpolate | The time corresponding to the scan to be demuxed |
[in] | intensities | A matrix of intensities of a number of nearby spectra. Each spectrum should have a row of transitions. |
[in] | scanTimes | A vector of scanTimes. Because the same scan times are used for every transition in a given spectrum it is only necessary to pass a vector of scanTimes rather than a matrix. This vector is reused for interpolating every transition. |
◆ InterpolateMatrix()
static double pwiz::analysis::OverlapDemultiplexer::InterpolateMatrix |
( |
double |
pointToInterpolate, |
|
|
Eigen::Ref< const Eigen::VectorXd > |
points, |
|
|
Eigen::Ref< const Eigen::VectorXd > |
values |
|
) |
| |
|
staticprotected |
Takes two vectors of equal length and solves an interpolation for the given point.
- Parameters
-
pointToInterpolate | Independent variable to interpolate |
points | The independent values as a monotonically increasing series |
values | The dependent values |
- Returns
- Returns the solved interpolation value
- Precondition
- points must be sorted in order of increasing value with no duplicates
-
points and values must be of the same size
◆ overlapRegionsInApprox_
size_t pwiz::analysis::OverlapDemultiplexer::overlapRegionsInApprox_ |
|
private |
The number of mux spectra nearby the spectrum to demux (in both retention time and m/z space) to use for demuxing.
Definition at line 99 of file OverlapDemultiplexer.hpp.
◆ cyclesInBlock_
size_t pwiz::analysis::OverlapDemultiplexer::cyclesInBlock_ |
|
private |
The number of spectra with identical isolation parameters to use for interpolation.
Definition at line 102 of file OverlapDemultiplexer.hpp.
◆ sl_
◆ pmc_
◆ params_
Params pwiz::analysis::OverlapDemultiplexer::params_ |
|
private |
◆ spectrumIndices_
std::vector<size_t> pwiz::analysis::OverlapDemultiplexer::spectrumIndices_ |
|
private |
The documentation for this class was generated from the following file: