30 using namespace pwiz::analysis;
31 using namespace pwiz::util;
33 using namespace pwiz::msdata;
66 unit_assert(sl->spectrumIdentity(0).id ==
"scan=20");
68 vector<double> profileData(sl->spectrum(0)->getMZArray()->data);
78 vector<double> peakData(sl->spectrum(0)->getMZArray()->data);
96 double timeHighInSeconds = 5.9 * 60;
98 oss <<
"scanTime [0," << timeHighInSeconds <<
"]";
101 unit_assert(sl->spectrumIdentity(0).id ==
"scan=19");
102 unit_assert(sl->spectrumIdentity(1).id ==
"sample=1 period=1 cycle=23 experiment=1");
120 unit_assert(sl->spectrumIdentity(0).id ==
"scan=21");
121 unit_assert(sl->spectrumIdentity(1).id ==
"scan=19");
122 unit_assert(sl->spectrumIdentity(2).id ==
"sample=1 period=1 cycle=23 experiment=1");
134 vector<MZIntensityPair> data;
135 spectrum->getMZIntensityPairs(data);
140 spectrum = sl->spectrum(0,
true);
141 spectrum->getMZIntensityPairs(data);
144 spectrum = sl->spectrum(1,
true);
145 spectrum->getMZIntensityPairs(data);
424 SpectrumListFactory::wrap(msd,
"titleMaker <ScanNumber> <MsLevel> <ActivationType> <ChargeState> <PrecursorSpectrumId>");
451 int main(
int argc,
char* argv[])
457 if (argc>1 && !strcmp(argv[1],
"-v"))
os_ = &cout;
static void wrap(msdata::MSData &msd, const std::string &wrapper)
instantiate the SpectrumListWrapper indicated by wrapper
void testWrapScanTimeRange()
PWIZ_API_DECL const CV & cv(const std::string &prefix)
returns a CV object for the specified namespace (prefix); currently supported namespaces are: MS UO ...
#define unit_assert_throws(x, exception)
void testWrapMassAnalyzer()
void testWrapTitleMaker()
static std::string usage(bool detailedHelp=true, const char *morehelp_prompt=NULL)
user-friendly documentation, with option of less or more detail
boost::shared_ptr< Spectrum > SpectrumPtr
MS_scan_start_time
scan start time: The time that an analyzer started a scan, relative to the start of the MS run...
void testWrapActivation()
void testWrapDefaultArrayLength()
UO_second
second: A time unit which is equal to the duration of 9 192 631 770 periods of the radiation correspo...
int main(int argc, char *argv[])
#define unit_assert_operator_equal(expected, actual)
Run run
a run in mzML should correspond to a single, consecutive and coherent set of scans on an instrument...
boost::shared_ptr< SpectrumList > SpectrumListPtr
std::vector< DataProcessingPtr > allDataProcessingPtrs() const
return dataProcessingPtrs augmented by the dataProcessingPtr() set in SpectrumList and/or Chromatogra...
UO_minute
minute: A time unit which is equal to 60 seconds.
SpectrumListPtr spectrumListPtr
all mass spectra and the acquisitions underlying them are described and attached here. Subsidiary data arrays are also both described and attached here.
MS_spectrum_title
spectrum title: A free-form text title describing a spectrum.
void testWrapChargeState()
PWIZ_API_DECL void initializeTiny(IdentData &mzid)
void testWrapSortScanTime()
#define TEST_PROLOG(argc, argv)
This is the root element of ProteoWizard; it represents the mzML element, defined as: intended to cap...