This function takes a vector or matrix of data and smooths the data with an improved Savitzky Golay transform. The SavitzkyGolay method for data smoothing and differentiation calculates convolution weights using Gram polynomials that exactly reproduce the results of leastsquares polynomial regression. Use of the SavitzkyGolay method requires specification of both filter length and polynomial degree to calculate convolution weights. For maximum smoothing of statistical noise in data, polynomials with low degrees are desirable, while a high polynomial degree is necessary for accurate reproduction of peaks in the data. Extension of the leastsquares regression formalism with statistical testing of additional terms of polynomial degree to a heuristically chosen minimum for each data window leads to an adaptivedegree polynomial filter (ADPF). Based on noise reduction for data that consist of pure noise and on signal reproduction for data that is purely signal, ADPF performed nearly as well as the optimally chosen fixeddegree SavitzkyGolay filter and outperformed suboptimally chosen SavitzkyGolay filters. For synthetic data consisting of noise and signal, ADPF outperformed both optimally chosen and suboptimally chosen fixeddegree SavitzkyGolay filters. See Barak, P. (1995) <doi:10.1021/ac00113a006> for more information.
Package details 


Author  Phillip Barak [aut], Samuel Kruse [cre, aut] 
Maintainer  Samuel Kruse <samdkruse@gmail.com> 
License  GPL3 
Version  0.0.1 
Package repository  View on CRAN 
Installation 
Install the latest version of this package by entering the following in R:

Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.