matchms.filtering.metadata_processing.add_compound_name module

matchms.filtering.metadata_processing.add_compound_name.add_compound_name(spectrum_in: Spectrum, clone: bool | None = True) Spectrum | None[source]

Add compound_name to correct field: “compound_name” in metadata.

Parameters:
  • spectrum_in – Input spectrum.

  • clone – Optionally clone the Spectrum.

Returns:

Spectrum with added compound name, or None if not present.

Return type:

Spectrum or None