35 #ifndef OPENMS_KERNEL_ONDISCMSEXPERIMENT_H 36 #define OPENMS_KERNEL_ONDISCMSEXPERIMENT_H 51 #include <boost/shared_ptr.hpp> 97 if (filename !=
"" && !skipMetaData)
193 spectrum.reserve(mz_arr->data.size());
194 for (
Size i = 0; i < mz_arr->data.size(); i++)
197 p.
setMZ(mz_arr->data[i]);
199 spectrum.push_back(p);
225 chromatogram.reserve(rt_arr->data.size());
226 for (
Size i = 0; i < rt_arr->data.size(); i++)
229 p.
setRT(rt_arr->data[i]);
231 chromatogram.push_back(p);
263 f.setOptions(options);
282 #endif // OPENMS_KERNEL_ONDISCMSEXPERIMENT_H boost::shared_ptr< Spectrum > SpectrumPtr
Definition: openms/include/OpenMS/INTERFACES/DataStructures.h:237
void setRT(CoordinateType rt)
Mutable access to RT.
Definition: ChromatogramPeak.h:117
Size getNrChromatograms() const
get the total number of chromatograms available
Definition: OnDiscMSExperiment.h:163
void setSkipXMLChecks(bool skip)
Whether to skip some XML checks (removing whitespace from base64 arrays) and be fast instead...
Definition: IndexedMzMLFile.h:168
boost::shared_ptr< Chromatogram > ChromatogramPtr
Definition: openms/include/OpenMS/INTERFACES/DataStructures.h:157
A more convenient string class.
Definition: String.h:57
bool openFile(const String &filename, bool skipMetaData=false)
Open a specific file on disk.
Definition: OnDiscMSExperiment.h:93
The representation of a chromatogram.
Definition: MSChromatogram.h:55
MSSpectrum operator[](Size n)
alias for getSpectrum
Definition: OnDiscMSExperiment.h:175
size_t getNrChromatograms() const
Returns the number of chromatograms available.
boost::shared_ptr< BinaryDataArray > BinaryDataArrayPtr
Definition: openms/include/OpenMS/INTERFACES/DataStructures.h:81
Peak1D PeakT
Definition: OnDiscMSExperiment.h:73
bool isSortedByRT() const
Checks if all spectra are sorted with respect to ascending RT.
Definition: OnDiscMSExperiment.h:139
OnDiscMSExperiment & operator=(const OnDiscMSExperiment &)
Private Assignment operator -> we cannot copy file streams in IndexedMzMLFile.
OpenMS::Interfaces::ChromatogramPtr getChromatogramById(int id)
Retrieve the raw data for the chromatogram at position "id".
size_t getNrSpectra() const
Returns the number of spectra available.
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:47
void setMZ(CoordinateType mz)
Mutable access to m/z.
Definition: Peak1D.h:120
void setIntensity(IntensityType intensity)
Mutable access to the data point intensity (height)
Definition: Peak1D.h:111
bool operator==(const OnDiscMSExperiment &rhs) const
Equality operator.
Definition: OnDiscMSExperiment.h:119
void openFile(String filename)
Open a file.
Size size() const
alias for getNrSpectra
Definition: OnDiscMSExperiment.h:145
String filename_
The filename of the underlying data file.
Definition: OnDiscMSExperiment.h:271
File adapter for MzML files.
Definition: MzMLFile.h:56
MSChromatogram getChromatogram(Size id)
returns a single chromatogram
Definition: OnDiscMSExperiment.h:217
Representation of a mass spectrometry experiment on disk.
Definition: OnDiscMSExperiment.h:69
The representation of a 1D spectrum.
Definition: MSSpectrum.h:67
OnDiscMSExperiment()
Constructor.
Definition: OnDiscMSExperiment.h:82
boost::shared_ptr< const ExperimentalSettings > getExperimentalSettings() const
returns the meta information of this experiment (const access)
Definition: OnDiscMSExperiment.h:169
MSExperiment PeakMap
Two-dimensional map of raw data points or peaks.
Definition: StandardTypes.h:59
A low-level class to read an indexedmzML file.
Definition: IndexedMzMLFile.h:74
MSSpectrum getSpectrum(Size id)
returns a single spectrum
Definition: OnDiscMSExperiment.h:185
OpenMS::Interfaces::SpectrumPtr getSpectrumById(Size id)
returns a single spectrum
Definition: OnDiscMSExperiment.h:207
A 1-dimensional raw data point or peak.
Definition: Peak1D.h:55
OpenMS::Interfaces::ChromatogramPtr getChromatogramById(Size id)
returns a single chromatogram
Definition: OnDiscMSExperiment.h:240
boost::shared_ptr< PeakMap > meta_ms_experiment_
The meta-data.
Definition: OnDiscMSExperiment.h:275
ChromatogramPeak ChromatogramPeakT
Definition: OnDiscMSExperiment.h:72
OpenMS::Interfaces::SpectrumPtr getSpectrumById(int id)
Retrieve the raw data for the spectrum at position "id".
OnDiscMSExperiment(const OnDiscMSExperiment &source)
Copy constructor.
Definition: OnDiscMSExperiment.h:105
void setIntensity(IntensityType intensity)
Mutable access to the data point intensity (height)
Definition: ChromatogramPeak.h:108
size_t Size
Size type e.g. used as variable which can hold result of size()
Definition: Types.h:128
OpenMS::OnDiscMSExperiment OnDiscPeakMap
Definition: OnDiscMSExperiment.h:278
A 1-dimensional raw data point or peak for chromatograms.
Definition: ChromatogramPeak.h:55
bool empty() const
returns whether spectra are empty
Definition: OnDiscMSExperiment.h:151
Size getNrSpectra() const
get the total number of spectra available
Definition: OnDiscMSExperiment.h:157
void loadMetaData_(const String &filename)
Definition: OnDiscMSExperiment.h:256
Options for loading files containing peak data.
Definition: PeakFileOptions.h:48
IndexedMzMLFile indexed_mzml_file_
The index of the underlying data file.
Definition: OnDiscMSExperiment.h:273
void setFillData(bool only)
sets whether to fill the actual data into the container (spectrum/chromatogram)
bool operator!=(const OnDiscMSExperiment &rhs) const
Inequality operator.
Definition: OnDiscMSExperiment.h:128
Description of the experimental settings.
Definition: ExperimentalSettings.h:59
void setSkipXMLChecks(bool skip)
sets whether to skip some XML checks and be fast instead
Definition: OnDiscMSExperiment.h:246
bool getParsingSuccess() const
Returns whether parsing was successful.