SpectrumAnnotator#
- class pyopenms.SpectrumAnnotator#
Bases:
objectCython implementation of _SpectrumAnnotator
- Original C++ documentation is available here
– Inherits from [‘DefaultParamHandler’]
- __init__()#
Overload:
- __init__(self) None
Annotates spectra from identifications and theoretical spectra or identifications from spectra and theoretical spectra matching with various options
Overload:
- __init__(self, in_0: SpectrumAnnotator) None
Methods
addIonMatchStatistics(self, pi, spec, tg, sa)Adds ion match statistics to pi PeptideIdentifcation
addPeakAnnotationsToPeptideHit(self, ph, ...)Adds peak annotations to the ph PeptideHit
annotateMatches(self, spec, ph, tg, sa)Adds ion match annotation to the spec input spectrum
getDefaults(self)Returns the default parameters
getName(self)Returns the name
getParameters(self)Returns the parameters
getSubsections(self)setName(self, in_0)Sets the name
setParameters(self, param)Sets the parameters
- addIonMatchStatistics(self, pi: PeptideIdentification, spec: MSSpectrum, tg: TheoreticalSpectrumGenerator, sa: SpectrumAlignment) None#
Adds ion match statistics to pi PeptideIdentifcation
- Parameters:
pi – A spectrum identifications to be annotated, looking up matches from a spectrum and the theoretical spectrum inferred from the identifications sequence
spec – A PeakSpectrum containing the peaks from which the pi identifications are made
tg – A TheoreticalSpectrumGenerator to infer the theoretical spectrum. Its own parameters define which ion types are referred
sa – A SpectrumAlignment to match the theoretical spectrum with the measured. Its own parameters define the match tolerance
- addPeakAnnotationsToPeptideHit(self, ph: PeptideHit, spec: MSSpectrum, tg: TheoreticalSpectrumGenerator, sa: SpectrumAlignment, include_unmatched_peaks: bool) None#
Adds peak annotations to the ph PeptideHit
- Parameters:
ph – A PeptideHit whose PeakAnnotations vector will be filled with the ion matches
spec – A PeakSpectrum containing the peaks from which the ph identifications are made
tg – A TheoreticalSpectrumGenerator to infer the theoretical spectrum. Its own parameters define which ion types are referred
sa – A SpectrumAlignment to match the theoretical spectrum with the measured. Its own parameters define the match tolerance
include_unmatched_peaks – If true, all spectrum peaks will be included in the PeakAnnotations vector. Unmatched peaks will have empty annotation strings. If false, only matched peaks are included.
- annotateMatches(self, spec: MSSpectrum, ph: PeptideHit, tg: TheoreticalSpectrumGenerator, sa: SpectrumAlignment) None#
Adds ion match annotation to the spec input spectrum
- Parameters:
spec – A PeakSpectrum containing the peaks from which the pi identifications are made
ph – A spectrum identifications to be used for the annotation, looking up matches from a spectrum and the theoretical spectrum inferred from the identifications sequence
tg – A TheoreticalSpectrumGenerator to infer the theoretical spectrum. Its own parameters define which ion types are referred
sa – A SpectrumAlignment to match the theoretical spectrum with the measured. Its own parameters define the match tolerance
- getSubsections(self) List[bytes]#