MascotXMLFile#

class pyopenms.MascotXMLFile#

Bases: object

Cython implementation of _MascotXMLFile

Original C++ documentation is available here

– Inherits from [‘XMLFile’]

__init__()#

Overload:

__init__(self) None

Overload:

__init__(self, in_0: MascotXMLFile) None

Methods

__init__

Overload:

getVersion(self)

Return the version of the schema

initializeLookup(self, lookup, experiment, ...)

Initializes a helper object for looking up spectrum meta data (RT, m/z)

load(self, filename, protein_identification, ...)

Loads data from a Mascot XML file

getVersion(self) bytes | str | String#

Return the version of the schema

initializeLookup(self, lookup: SpectrumMetaDataLookup, experiment: MSExperiment, scan_regex: bytes | str | String) None#

Initializes a helper object for looking up spectrum meta data (RT, m/z)

Parameters:
  • lookup – Helper object to initialize

  • experiment – Experiment containing the spectra

  • scan_regex – Optional regular expression for extracting information from references to spectra

load(self, filename: bytes | str | String, protein_identification: ProteinIdentification, id_data: List[PeptideIdentification], rt_mapping: SpectrumMetaDataLookup) None#

Loads data from a Mascot XML file

Parameters:
  • filename – The file to be loaded

  • protein_identification – Protein identifications belonging to the whole experiment

  • id_data – The identifications with m/z and RT

  • lookup – Helper object for looking up spectrum meta data

Raises:

Exception: FileNotFound is thrown if the file does not exists

Raises:

Exception: ParseError is thrown if the file does not suit to the standard