MCPcopy Create free account
hub / github.com/OpenMS/OpenMS / insertCalibrationPoint

Method insertCalibrationPoint

src/openms/source/DATASTRUCTURES/CalibrationData.cpp:77–95  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

75 }
76
77 void CalibrationData::insertCalibrationPoint( CalDataType::CoordinateType rt,
78 CalDataType::CoordinateType mz_obs,
79 CalDataType::IntensityType intensity,
80 CalDataType::CoordinateType mz_ref,
81 double weight,
82 int group /*= -1*/ )
83 {
84 RichPeak2D p(Peak2D::PositionType(rt, mz_obs), intensity);
85 p.setMetaValue("mz_ref", mz_ref);
86 p.setMetaValue("ppm_error", Math::getPPM(mz_obs, mz_ref));
87 p.setMetaValue("weight", weight);
88
89 if (group >= 0)
90 {
91 p.setMetaValue("peakgroup", group);
92 groups_.insert(group);
93 }
94 data_.push_back(p);
95 }
96
97 Size CalibrationData::getNrOfGroups() const
98 {

Callers 5

medianMethod · 0.80
fillCalibrantsMethod · 0.80
fillID_Method · 0.80

Calls 4

getPPMFunction · 0.85
setMetaValueMethod · 0.45
insertMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected