Cargando…
Why and How Savitzky–Golay Filters Should Be Replaced
[Image: see text] Savitzky–Golay (SG) filtering, based on local least-squares fitting of the data by polynomials, is a popular method for smoothing data and calculations of derivatives of noisy data. At frequencies above the cutoff, SG filters have poor noise suppression; this unnecessarily reduces...
Autores principales: | , , |
---|---|
Formato: | Online Artículo Texto |
Lenguaje: | English |
Publicado: |
American Chemical Society
2022
|
Acceso en línea: | https://www.ncbi.nlm.nih.gov/pmc/articles/PMC9026279/ https://www.ncbi.nlm.nih.gov/pubmed/35479103 http://dx.doi.org/10.1021/acsmeasuresciau.1c00054 |
_version_ | 1784691084308250624 |
---|---|
author | Schmid, Michael Rath, David Diebold, Ulrike |
author_facet | Schmid, Michael Rath, David Diebold, Ulrike |
author_sort | Schmid, Michael |
collection | PubMed |
description | [Image: see text] Savitzky–Golay (SG) filtering, based on local least-squares fitting of the data by polynomials, is a popular method for smoothing data and calculations of derivatives of noisy data. At frequencies above the cutoff, SG filters have poor noise suppression; this unnecessarily reduces the signal-to-noise ratio, especially when calculating derivatives of the data. In addition, SG filtering near the boundaries of the data range is prone to artifacts, which are especially strong when using SG filters for calculating derivatives of the data. We show how these disadvantages can be avoided while keeping the advantageous properties of SG filters. We present two classes of finite impulse response (FIR) filters with substantially improved frequency response: (i) SG filters with fitting weights in the shape of a window function and (ii) convolution kernels based on the sinc function with a Gaussian-like window function and additional corrections for improving the frequency response in the passband (modified sinc kernel). Compared with standard SG filters, the only price to pay for the improvement is a moderate increase in the kernel size. Smoothing at the boundaries of the data can be improved with a non-FIR method, the Whittaker–Henderson smoother, or by linear extrapolation of the data, followed by convolution with a modified sinc kernel, and we show that the latter is preferable in most cases. We provide computer programs and equations for the smoothing parameters of these smoothers when used as plug-in replacements for SG filters and describe how to choose smoothing parameters to preserve peak heights in spectra. |
format | Online Article Text |
id | pubmed-9026279 |
institution | National Center for Biotechnology Information |
language | English |
publishDate | 2022 |
publisher | American Chemical Society |
record_format | MEDLINE/PubMed |
spelling | pubmed-90262792022-04-25 Why and How Savitzky–Golay Filters Should Be Replaced Schmid, Michael Rath, David Diebold, Ulrike ACS Meas Sci Au [Image: see text] Savitzky–Golay (SG) filtering, based on local least-squares fitting of the data by polynomials, is a popular method for smoothing data and calculations of derivatives of noisy data. At frequencies above the cutoff, SG filters have poor noise suppression; this unnecessarily reduces the signal-to-noise ratio, especially when calculating derivatives of the data. In addition, SG filtering near the boundaries of the data range is prone to artifacts, which are especially strong when using SG filters for calculating derivatives of the data. We show how these disadvantages can be avoided while keeping the advantageous properties of SG filters. We present two classes of finite impulse response (FIR) filters with substantially improved frequency response: (i) SG filters with fitting weights in the shape of a window function and (ii) convolution kernels based on the sinc function with a Gaussian-like window function and additional corrections for improving the frequency response in the passband (modified sinc kernel). Compared with standard SG filters, the only price to pay for the improvement is a moderate increase in the kernel size. Smoothing at the boundaries of the data can be improved with a non-FIR method, the Whittaker–Henderson smoother, or by linear extrapolation of the data, followed by convolution with a modified sinc kernel, and we show that the latter is preferable in most cases. We provide computer programs and equations for the smoothing parameters of these smoothers when used as plug-in replacements for SG filters and describe how to choose smoothing parameters to preserve peak heights in spectra. American Chemical Society 2022-02-18 /pmc/articles/PMC9026279/ /pubmed/35479103 http://dx.doi.org/10.1021/acsmeasuresciau.1c00054 Text en © 2022 The Authors. Published by American Chemical Society https://creativecommons.org/licenses/by/4.0/Permits the broadest form of re-use including for commercial purposes, provided that author attribution and integrity are maintained (https://creativecommons.org/licenses/by/4.0/). |
spellingShingle | Schmid, Michael Rath, David Diebold, Ulrike Why and How Savitzky–Golay Filters Should Be Replaced |
title | Why and How Savitzky–Golay Filters Should Be
Replaced |
title_full | Why and How Savitzky–Golay Filters Should Be
Replaced |
title_fullStr | Why and How Savitzky–Golay Filters Should Be
Replaced |
title_full_unstemmed | Why and How Savitzky–Golay Filters Should Be
Replaced |
title_short | Why and How Savitzky–Golay Filters Should Be
Replaced |
title_sort | why and how savitzky–golay filters should be
replaced |
url | https://www.ncbi.nlm.nih.gov/pmc/articles/PMC9026279/ https://www.ncbi.nlm.nih.gov/pubmed/35479103 http://dx.doi.org/10.1021/acsmeasuresciau.1c00054 |
work_keys_str_mv | AT schmidmichael whyandhowsavitzkygolayfiltersshouldbereplaced AT rathdavid whyandhowsavitzkygolayfiltersshouldbereplaced AT dieboldulrike whyandhowsavitzkygolayfiltersshouldbereplaced |