OpenMS
FLASHDeconvSpectrumFile Class Reference

FLASHDeconv Spectrum level output *.tsv, *.msalign (for TopPIC) file formats. More...

#include <OpenMS/FORMAT/FLASHDeconvSpectrumFile.h>

Collaboration diagram for FLASHDeconvSpectrumFile:
[legend]

Static Public Member Functions

static void writeDeconvolvedMassesHeader (std::fstream &fs, uint ms_level, bool detail, bool report_decoy)
 write the header in the tsv output file (spectrum level) More...
 
static void writeDeconvolvedMasses (DeconvolvedSpectrum &dspec, std::fstream &fs, const String &file_name, const FLASHDeconvHelperStructs::PrecalculatedAveragine &avg, double tol, bool write_detail, bool record_decoy)
 write the deconvolved masses in the output file (spectrum level) More...
 
static void writeMzML (const MSExperiment &map, std::vector< DeconvolvedSpectrum > &deconvolved_spectra, const String &deconvolved_mzML_file, const String &annotated_mzML_file, int mzml_charge, DoubleList tols)
 
static void writeIsobaricQuantification (std::fstream &fs, std::vector< DeconvolvedSpectrum > &deconvolved_spectra)
 
static void writeDLMatrixHeader (std::fstream &fs)
 
static void writeDLMatrix (std::vector< DeconvolvedSpectrum > &dspecs, double tol, std::fstream &fs, const FLASHDeconvHelperStructs::PrecalculatedAveragine &avg)
 
static void writeTopFDHeader (std::fstream &fs, const Param &param)
 
static void writeTopFD (DeconvolvedSpectrum &dspec, std::fstream &fs, const String &filename, const double snr_threshold=1.0, const double qval_threshold=1.0, const uint min_ms_level=1, bool randomize_precursor_mass=false, bool randomize_fragment_mass=false)
 write the deconvolved masses TopFD output (*.msalign) More...
 

Static Private Attributes

static const int topFD_min_peak_count_ = 3
 number of minimum peak count in topFD msalign file More...
 
static const int topFD_max_peak_count_ = 500
 number of maximum peak count in topFD msalign file More...
 

Detailed Description

FLASHDeconv Spectrum level output *.tsv, *.msalign (for TopPIC) file formats.

Member Function Documentation

◆ writeDeconvolvedMasses()

static void writeDeconvolvedMasses ( DeconvolvedSpectrum dspec,
std::fstream &  fs,
const String file_name,
const FLASHDeconvHelperStructs::PrecalculatedAveragine avg,
double  tol,
bool  write_detail,
bool  record_decoy 
)
static

write the deconvolved masses in the output file (spectrum level)

Parameters
dspecdeconvolved spectrum to write
target_spectarget spectrum only used for decoy spectrum output
fsfile stream to the output file
file_namethe output file name that the deconvolved masses will be written.
avgaveragine information to calculate monoisotopic and average mass difference within this function. In PeakGroup (peaks of DeconvolvedSpectrum) only monoisotopic mass is recorded. To write both monoisotopic and average masses, their mass difference should be calculated using this averagine information.
tolmass tolerance
write_detailif this is set, more detailed information on each mass will be written in the output file.
record_decoyif set true, decoy and qvalue information will be written. Default MS1 headers are: FileName, ScanNum, TargetDecoyType, RetentionTime, MassCountInSpec, AverageMass, MonoisotopicMass, SumIntensity, MinCharge, MaxCharge, PeakCount, IsotopeCosine, ChargeScore, MassSNR, ChargeSNR, RepresentativeCharge, RepresentativeMzStart, RepresentativeMzEnd, setQscore, PerChargeIntensity, PerIsotopeIntensity

Default MS2 headers include MS1 headers plus: PrecursorScanNum, PrecursorMz, PrecursorIntensity, PrecursorCharge, PrecursorSNR, PrecursorMonoisotopicMass, PrecursorQscore

Detailed MS1 and MS2 headers include all corresponding headers above plus: PeakMZs, PeakIntensities, PeakCharges, PeakMasses, PeakIsotopeIndices, PeakPPMErrors

Referenced by TOPPFLASHDeconv::main_().

◆ writeDeconvolvedMassesHeader()

static void writeDeconvolvedMassesHeader ( std::fstream &  fs,
uint  ms_level,
bool  detail,
bool  report_decoy 
)
static

write the header in the tsv output file (spectrum level)

Parameters
fsfile stream to the output file
ms_levelms level of the spectrum
detailif set true, detailed information of the mass (e.g., peak list for the mass) is written
report_decoyif set true, decoy and qvalue information will be written.

Referenced by TOPPFLASHDeconv::main_().

◆ writeDLMatrix()

static void writeDLMatrix ( std::vector< DeconvolvedSpectrum > &  dspecs,
double  tol,
std::fstream &  fs,
const FLASHDeconvHelperStructs::PrecalculatedAveragine avg 
)
static

◆ writeDLMatrixHeader()

static void writeDLMatrixHeader ( std::fstream &  fs)
static

◆ writeIsobaricQuantification()

static void writeIsobaricQuantification ( std::fstream &  fs,
std::vector< DeconvolvedSpectrum > &  deconvolved_spectra 
)
static
Parameters
fs
deconvolved_spectra

Referenced by TOPPFLASHDeconv::main_().

◆ writeMzML()

static void writeMzML ( const MSExperiment map,
std::vector< DeconvolvedSpectrum > &  deconvolved_spectra,
const String deconvolved_mzML_file,
const String annotated_mzML_file,
int  mzml_charge,
DoubleList  tols 
)
static
Parameters
map
deconvolved_spectra
deconvolved_mzML_file
annotated_mzML_file
mzml_charge
tols

Referenced by TOPPFLASHDeconv::main_().

◆ writeTopFD()

static void writeTopFD ( DeconvolvedSpectrum dspec,
std::fstream &  fs,
const String filename,
const double  snr_threshold = 1.0,
const double  qval_threshold = 1.0,
const uint  min_ms_level = 1,
bool  randomize_precursor_mass = false,
bool  randomize_fragment_mass = false 
)
static

write the deconvolved masses TopFD output (*.msalign)

Parameters
dspecdeconvolved spectrum to write
fsfile stream to the output file
filenamemzml file name
snr_thresholdSNR threshold to filter out low SNR precursors. Even if a PeakGroup has a high deconvolution quality, it should be still discarded for identification when its precursor SNR (SNR within the isolation window) is too low.
qval_thresholdqvalue threshold to filter out high qvalue precursors.
min_ms_levelmin ms level of the dataset
randomize_precursor_massif set, a random number between -100 to 100 is added to precursor mass
randomize_fragment_massif set, a random number between -100 to 100 is added to fragment mass

Referenced by TOPPFLASHDeconv::main_().

◆ writeTopFDHeader()

static void writeTopFDHeader ( std::fstream &  fs,
const Param param 
)
static

Referenced by TOPPFLASHDeconv::main_().

Member Data Documentation

◆ topFD_max_peak_count_

const int topFD_max_peak_count_ = 500
staticprivate

number of maximum peak count in topFD msalign file

◆ topFD_min_peak_count_

const int topFD_min_peak_count_ = 3
staticprivate

number of minimum peak count in topFD msalign file