Peak detection
Peak detection is a crucial preprocessing step in spectral analysis that aims to identify and locate the prominent peaks within a spectrum. These peaks often correspond to specific chemical or physical properties of the sample being analyzed, and their accurate identification is essential for various applications, such as quantitative analysis, compound identification, and spectral deconvolution. Peak detection can be performed either automatically using algorithms or manually through user interaction.
Auto Peak Detection
Auto peak detection is a method that automatically identifies and locates the peaks in a spectrum based on predefined criteria. This approach is particularly useful when dealing with large datasets or when manual peak picking is impractical or time-consuming.
Configurable Parameters:
- Prominence (%): This parameter specifies the minimum prominence of a peak, which is the vertical distance between the peak and its lowest contour line. The prominence is expressed as a percentage of the signal's amplitude range. A higher prominence value will result in fewer peaks being detected, as only the most prominent peaks will satisfy the condition. A lower prominence value will allow for the detection of smaller peaks.
- Height: This parameter specifies the minimum height required for a peak to be considered significant. Any peaks below this height threshold will be ignored.
- Let be the input 1-D array of length .
- For each index in the range , check if is a local maximum by comparing it with its neighbors:
and
- If this condition is satisfied, is considered a potential peak. For each potential peak , calculate its prominence , which is the vertical distance between and its lowest contour line. The lowest contour line is determined by extending horizontal lines to the left and right of until they intersect with lower peaks or the signal borders. Mathematically, if and are the intersection points to the left and right of , respectively, then:
- The remaining peaks after applying the prominence and height filters are considered the detected peaks.
You have a spectrum representing the absorption of a sample at different wavelengths. You want to identify the prominent peaks in this spectrum, which may correspond to the presence of specific chemical compounds. By setting the prominence parameter to a higher value (e.g., 10%), you can ensure that only the most significant peaks are detected, ignoring smaller fluctuations or noise. Additionally, you can set a minimum height threshold to further filter out any peaks that are below a certain intensity level.
Manual Peak Picking
Manual peak picking is a method that allows the user to visually identify and select peaks of interest in a spectrum. This approach is particularly useful when the user already has prior knowledge about a subset of peaks and wants to examine their heights or compare them across different measurements.
The manual peak picking tool transforms the annotations made by the user over the spectrum into a set of points.
Imagine you are analyzing spectra of different chemical compound mixtures, and you are particularly interested in identifying the relative concentrations of a specific chemical bond. Based on prior knowledge or reference data, you know the peak location associated with this chemical bond. By employing manual peak picking, you can relatively quantify the presence of the bond across the different mixtures.