modifinder.Spectrum.update
- Spectrum.update(peaks=None, peaks_json=None, mz=None, intensity=None, precursor_mz=None, precursor_charge=None, adduct=None, ms_level=None, instrument=None, ms_mass_analyzer=None, ms_dissociation_method=None, spectrum_id=None, normalize_peaks=False, ratio_to_base_peak=None, remove_large_peaks=False, **kwargs)[source]
Update the Spectrum object with the given values.
- Parameters:
peaks (list) – A list of peaks in the form of [[mz1, intensity1], [mz2, intensity2], …].
peaks_json (str) – A json string of peaks.
mz (list) – A list of m/z values.
intensity (list) – A list of intensity values.
precursor_mz (float) – The precursor m/z value.
precursor_charge (int) – The precursor charge.
adduct (str) – The adduct.
ms_level (int) – The ms level.
instrument (str) – The instrument used.
ms_mass_analyzer (str) – The mass analyzer used.
ms_dissociation_method (str) – The dissociation method used.
spectrum_id (str) – The spectrum id.
normalize_peaks (bool) – If True, the intensity of the peaks will be normalized.
ratio_to_base_peak (float) – If None, no filtering is done, if a float number, it removes all the peaks with intensity
peak. (less than ratio times the base) –